summaryrefslogtreecommitdiff
path: root/eclass
diff options
context:
space:
mode:
authorRyan Hill <dirtyepic@gentoo.org>2013-08-10 07:41:19 +0000
committerRyan Hill <dirtyepic@gentoo.org>2013-08-10 07:41:19 +0000
commit94759067bf0fa6c0620b025c9bb6c0f4dcde4776 (patch)
treeaf7070864c336df9a0a5388bebddfe5f83e9e67f /eclass
parentP.use.force app-doc/pms binary because of unkeyworded texlive dependency. (diff)
downloadgentoo-2-94759067bf0fa6c0620b025c9bb6c0f4dcde4776.tar.gz
gentoo-2-94759067bf0fa6c0620b025c9bb6c0f4dcde4776.tar.bz2
gentoo-2-94759067bf0fa6c0620b025c9bb6c0f4dcde4776.zip
Clean up gcc_do_filter_flags a bit more. Drop ppc64 workaround for 3.2/3.3
as neither is keyworded. Also stop replacing -march=i686 with x86-64 (?!) for those versions.
Diffstat (limited to 'eclass')
-rw-r--r--eclass/ChangeLog7
-rw-r--r--eclass/toolchain.eclass92
2 files changed, 53 insertions, 46 deletions
diff --git a/eclass/ChangeLog b/eclass/ChangeLog
index 3b7a93e6181f..83b8fc0be45f 100644
--- a/eclass/ChangeLog
+++ b/eclass/ChangeLog
@@ -1,6 +1,11 @@
# ChangeLog for eclass directory
# Copyright 1999-2013 Gentoo Foundation; Distributed under the GPL v2
-# $Header: /var/cvsroot/gentoo-x86/eclass/ChangeLog,v 1.919 2013/08/10 04:25:37 dirtyepic Exp $
+# $Header: /var/cvsroot/gentoo-x86/eclass/ChangeLog,v 1.920 2013/08/10 07:41:19 dirtyepic Exp $
+
+ 10 Aug 2013; Ryan Hill <dirtyepic@gentoo.org> toolchain.eclass:
+ Clean up gcc_do_filter_flags a bit more. Drop ppc64 workaround for 3.2/3.3
+ as neither is keyworded. Also stop replacing -march=i686 with x86-64 (?!) for
+ those versions.
10 Aug 2013; Ryan Hill <dirtyepic@gentoo.org> toolchain.eclass:
Append -Wl,--no-relax to LDFLAGS on alpha for 4.6 (bug #454426 again).
diff --git a/eclass/toolchain.eclass b/eclass/toolchain.eclass
index a55805ab70e9..121958f6f8d8 100644
--- a/eclass/toolchain.eclass
+++ b/eclass/toolchain.eclass
@@ -1,6 +1,6 @@
# Copyright 1999-2013 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
-# $Header: /var/cvsroot/gentoo-x86/eclass/toolchain.eclass,v 1.598 2013/08/10 04:25:37 dirtyepic Exp $
+# $Header: /var/cvsroot/gentoo-x86/eclass/toolchain.eclass,v 1.599 2013/08/10 07:41:19 dirtyepic Exp $
# Maintainer: Toolchain Ninjas <toolchain@gentoo.org>
@@ -1389,56 +1389,58 @@ gcc_do_filter_flags() {
filter-flags '-mabi*' -m31 -m32 -m64
case ${GCC_BRANCH_VER} in
- 3.2|3.3)
- replace-cpu-flags k8 athlon64 opteron i686 x86-64
- replace-cpu-flags pentium-m pentium3m pentium3
- case $(tc-arch) in
- amd64|x86) filter-flags '-mtune=*' ;;
- # in gcc 3.3 there is a bug on ppc64 where if -mcpu is used,
- # the compiler wrongly assumes a 32bit target
- ppc64) filter-flags "-mcpu=*";;
- esac
- case $(tc-arch) in
- amd64) replace-cpu-flags core2 nocona;;
- x86) replace-cpu-flags core2 prescott;;
- esac
-
- replace-cpu-flags G3 750
- replace-cpu-flags G4 7400
- replace-cpu-flags G5 7400
+ 3.2|3.3)
+ replace-cpu-flags k8 athlon64 opteron x86-64
+ replace-cpu-flags pentium-m pentium3m pentium3
+ replace-cpu-flags G3 750
+ replace-cpu-flags G4 7400
+ replace-cpu-flags G5 7400
+
+ case $(tc-arch) in
+ amd64)
+ replace-cpu-flags core2 nocona
+ filter-flags '-mtune=*'
+ ;;
+ x86)
+ replace-cpu-flags core2 prescott
+ filter-flags '-mtune=*'
+ ;;
+ esac
- # XXX: should add a sed or something to query all supported flags
- # from the gcc source and trim everything else ...
- filter-flags -f{no-,}unit-at-a-time -f{no-,}web -mno-tls-direct-seg-refs
- filter-flags -f{no-,}stack-protector{,-all}
- filter-flags -fvisibility-inlines-hidden -fvisibility=hidden
- ;;
- 3.4|4.*)
- case $(tc-arch) in
- x86|amd64) filter-flags '-mcpu=*';;
- *-macos)
- # http://gcc.gnu.org/bugzilla/show_bug.cgi?id=25127
- [[ ${GCC_BRANCH_VER} == 4.0 || ${GCC_BRANCH_VER} == 4.1 ]] && \
- filter-flags '-mcpu=*' '-march=*' '-mtune=*'
+ # XXX: should add a sed or something to query all supported flags
+ # from the gcc source and trim everything else ...
+ filter-flags -f{no-,}unit-at-a-time -f{no-,}web -mno-tls-direct-seg-refs
+ filter-flags -f{no-,}stack-protector{,-all}
+ filter-flags -fvisibility-inlines-hidden -fvisibility=hidden
+ ;;
+ 3.4|4.*)
+ case $(tc-arch) in
+ amd64|x86)
+ filter-flags '-mcpu=*'
+ ;;
+ *-macos)
+ # http://gcc.gnu.org/PR25127
+ [[ ${GCC_BRANCH_VER} == 4.0 || ${GCC_BRANCH_VER} == 4.1 ]] && \
+ filter-flags '-mcpu=*' '-march=*' '-mtune=*'
+ ;;
+ esac
;;
- esac
- ;;
esac
case ${GCC_BRANCH_VER} in
- 4.6)
- case $(tc-arch) in
- alpha)
- # https://bugs.gentoo.org/454426
- append-ldflags -Wl,--no-relax
- ;;
- amd64|x86)
- # https://bugs.gentoo.org/411333
- # https://bugs.gentoo.org/466454
- replace-cpu-flags c3-2 pentium2 pentium3 pentium3m pentium-m i686
+ 4.6)
+ case $(tc-arch) in
+ alpha)
+ # https://bugs.gentoo.org/454426
+ append-ldflags -Wl,--no-relax
+ ;;
+ amd64|x86)
+ # https://bugs.gentoo.org/411333
+ # https://bugs.gentoo.org/466454
+ replace-cpu-flags c3-2 pentium2 pentium3 pentium3m pentium-m i686
+ ;;
+ esac
;;
- esac
- ;;
esac
strip-unsupported-flags