diff options
author | Davide Pesavento <pesa@gentoo.org> | 2015-03-23 02:15:14 +0000 |
---|---|---|
committer | Davide Pesavento <pesa@gentoo.org> | 2015-03-23 02:15:14 +0000 |
commit | 2f7c01c94fd0839fa381985319134f608ef1915b (patch) | |
tree | dc99ba12d8b873be85c24c9b25585a34a3a6e6fc /eclass | |
parent | update to 2015.02 to fix bug #543788 (diff) | |
download | gentoo-2-2f7c01c94fd0839fa381985319134f608ef1915b.tar.gz gentoo-2-2f7c01c94fd0839fa381985319134f608ef1915b.tar.bz2 gentoo-2-2f7c01c94fd0839fa381985319134f608ef1915b.zip |
Workaround toolchain bug on x86 with -Os and --as-needed, see bug #503500.
Diffstat (limited to 'eclass')
-rw-r--r-- | eclass/ChangeLog | 6 | ||||
-rw-r--r-- | eclass/qt4-build-multilib.eclass | 22 | ||||
-rw-r--r-- | eclass/qt4-build.eclass | 26 |
3 files changed, 36 insertions, 18 deletions
diff --git a/eclass/ChangeLog b/eclass/ChangeLog index c181c02bd0c3..c0eec7fcdc96 100644 --- a/eclass/ChangeLog +++ b/eclass/ChangeLog @@ -1,6 +1,10 @@ # ChangeLog for eclass directory # Copyright 1999-2015 Gentoo Foundation; Distributed under the GPL v2 -# $Header: /var/cvsroot/gentoo-x86/eclass/ChangeLog,v 1.1572 2015/03/22 13:41:16 mgorny Exp $ +# $Header: /var/cvsroot/gentoo-x86/eclass/ChangeLog,v 1.1573 2015/03/23 02:15:14 pesa Exp $ + + 23 Mar 2015; Davide Pesavento <pesa@gentoo.org> qt4-build.eclass, + qt4-build-multilib.eclass: + Workaround toolchain bug on x86 with -Os and --as-needed, see bug #503500. 22 Mar 2015; Michał Górny <mgorny@gentoo.org> python-single-r1.eclass: Extend EAPI=4 whitelist to cover crossdev gdb. diff --git a/eclass/qt4-build-multilib.eclass b/eclass/qt4-build-multilib.eclass index e8d9ffa0157e..48ad42dc4984 100644 --- a/eclass/qt4-build-multilib.eclass +++ b/eclass/qt4-build-multilib.eclass @@ -1,6 +1,6 @@ # Copyright 1999-2015 Gentoo Foundation # Distributed under the terms of the GNU General Public License v2 -# $Header: /var/cvsroot/gentoo-x86/eclass/qt4-build-multilib.eclass,v 1.7 2015/03/15 01:25:19 pesa Exp $ +# $Header: /var/cvsroot/gentoo-x86/eclass/qt4-build-multilib.eclass,v 1.8 2015/03/23 02:15:14 pesa Exp $ # @ECLASS: qt4-build-multilib.eclass # @MAINTAINER: @@ -167,17 +167,25 @@ qt4-build-multilib_src_prepare() { fi fi + if [[ ${PN} == qtcore ]]; then + # Bug 373061 + # qmake bus errors with -O2 or -O3 but -O1 works + if [[ ${CHOST} == *86*-apple-darwin* ]]; then + replace-flags -O[23] -O1 + fi + + # Bug 503500 + # undefined reference with -Os and --as-needed + if use x86 || use_if_iuse abi_x86_32; then + replace-flags -Os -O2 + fi + fi + # Bug 261632 if use ppc64; then append-flags -mminimal-toc fi - # Bug 373061 - # qmake bus errors with -O2 or -O3 but -O1 works - if [[ ${CHOST} == *86*-apple-darwin* ]]; then - replace-flags -O[23] -O1 - fi - # Bug 417105 # graphite on gcc 4.7 causes miscompilations if [[ $(gcc-version) == "4.7" ]]; then diff --git a/eclass/qt4-build.eclass b/eclass/qt4-build.eclass index 6e6008a72a48..4d20a6572acf 100644 --- a/eclass/qt4-build.eclass +++ b/eclass/qt4-build.eclass @@ -1,6 +1,6 @@ # Copyright 1999-2015 Gentoo Foundation # Distributed under the terms of the GNU General Public License v2 -# $Header: /var/cvsroot/gentoo-x86/eclass/qt4-build.eclass,v 1.161 2015/03/15 01:25:19 pesa Exp $ +# $Header: /var/cvsroot/gentoo-x86/eclass/qt4-build.eclass,v 1.162 2015/03/23 02:15:14 pesa Exp $ # @ECLASS: qt4-build.eclass # @MAINTAINER: @@ -172,10 +172,18 @@ qt4-build_src_prepare() { skip_qmake_build skip_project_generation symlink_binaries_to_buildtree - fi + else + # Bug 373061 + # qmake bus errors with -O2 or -O3 but -O1 works + if [[ ${CHOST} == *86*-apple-darwin* ]]; then + replace-flags -O[23] -O1 + fi - if use_if_iuse c++0x; then - append-cxxflags -std=c++0x + # Bug 503500 + # undefined reference with -Os and --as-needed + if use x86; then + replace-flags -Os -O2 + fi fi # Bug 261632 @@ -183,18 +191,16 @@ qt4-build_src_prepare() { append-flags -mminimal-toc fi - # Bug 373061 - # qmake bus errors with -O2 or -O3 but -O1 works - if [[ ${CHOST} == *86*-apple-darwin* ]]; then - replace-flags -O[23] -O1 - fi - # Bug 417105 # graphite on gcc 4.7 causes miscompilations if [[ $(gcc-version) == "4.7" ]]; then filter-flags -fgraphite-identity fi + if use_if_iuse c++0x; then + append-cxxflags -std=c++0x + fi + # Respect CC, CXX, {C,CXX,LD}FLAGS in .qmake.cache sed -e "/^SYSTEM_VARIABLES=/i \ CC='$(tc-getCC)'\n\ |