diff options
author | Mike Frysinger <vapier@gentoo.org> | 2004-10-13 14:11:52 +0000 |
---|---|---|
committer | Mike Frysinger <vapier@gentoo.org> | 2004-10-13 14:11:52 +0000 |
commit | 42346d050eb64a11ce6e5b88f50fcd6678da1ce4 (patch) | |
tree | 1c4608e483c49e55cdb39146a0c780c7b6343063 /eclass | |
parent | Stable on hppa. (Manifest recommit) (diff) | |
download | gentoo-2-42346d050eb64a11ce6e5b88f50fcd6678da1ce4.tar.gz gentoo-2-42346d050eb64a11ce6e5b88f50fcd6678da1ce4.tar.bz2 gentoo-2-42346d050eb64a11ce6e5b88f50fcd6678da1ce4.zip |
move gcc2-flags out of gcc.eclass and into flag-o-matic
Diffstat (limited to 'eclass')
-rw-r--r-- | eclass/flag-o-matic.eclass | 33 |
1 files changed, 32 insertions, 1 deletions
diff --git a/eclass/flag-o-matic.eclass b/eclass/flag-o-matic.eclass index fe9f66b89978..014b69bb3a87 100644 --- a/eclass/flag-o-matic.eclass +++ b/eclass/flag-o-matic.eclass @@ -1,6 +1,6 @@ # Copyright 1999-2004 Gentoo Foundation # Distributed under the terms of the GNU General Public License v2 -# $Header: /var/cvsroot/gentoo-x86/eclass/flag-o-matic.eclass,v 1.72 2004/10/09 18:28:46 vapier Exp $ +# $Header: /var/cvsroot/gentoo-x86/eclass/flag-o-matic.eclass,v 1.73 2004/10/13 14:11:52 vapier Exp $ # # Author Bart Verwilst <verwilst@gentoo.org> @@ -440,3 +440,34 @@ fstack-flags() { fi return 0 } + +# This is thanks to great work from Paul de Vrieze <gentoo-user@devrieze.net>, +# bug #9016. Also thanks to Jukka Salmi <salmi@gmx.net> (bug #13907) for more +# fixes. +# +# Export CFLAGS and CXXFLAGS that are compadible with gcc-2.95.3 +gcc2-flags() { + CFLAGS=${CFLAGS//pentium-mmx/i586} + CFLAGS=${CFLAGS//pentium[234]/i686} + CFLAGS=${CFLAGS//k6-[23]/k6} + CFLAGS=${CFLAGS//athlon-tbird/i686} + CFLAGS=${CFLAGS//athlon-4/i686} + CFLAGS=${CFLAGS//athlon-[xm]p/i686} + CFLAGS=${CFLAGS//athlon/i686} + + CXXFLAGS=${CXXFLAGS//pentium-mmx/i586} + CXXFLAGS=${CXXFLAGS//pentium[234]/i686} + CXXFLAGS=${CXXFLAGS//k6-[23]/k6} + CXXFLAGS=${CXXFLAGS//athlon-tbird/i686} + CXXFLAGS=${CXXFLAGS//athlon-4/i686} + CXXFLAGS=${CXXFLAGS//athlon-[xm]p/i686} + CXXFLAGS=${CXXFLAGS//athlon/i686} + + if [ "$ARCH" = alpha ]; then + CHOST=${CHOST/#alphaev6[78]/alphaev6} + CFLAGS=${CFLAGS//ev6[78]/ev6} + CXXFLAGS=${CXXFLAGS//ev6[78]/ev6} + fi + + export CFLAGS CXXFLAGS +} |