diff options
author | Mike Frysinger <vapier@gentoo.org> | 2007-10-11 05:27:57 +0000 |
---|---|---|
committer | Mike Frysinger <vapier@gentoo.org> | 2007-10-11 05:27:57 +0000 |
commit | 32aa3046a48c8f6057e48e9422d118ea3ef69ea9 (patch) | |
tree | 225c6ec4af39925e46f20f20530881002352e6eb /sys-devel/gcc-config | |
parent | old (diff) | |
download | gentoo-2-32aa3046a48c8f6057e48e9422d118ea3ef69ea9.tar.gz gentoo-2-32aa3046a48c8f6057e48e9422d118ea3ef69ea9.tar.bz2 gentoo-2-32aa3046a48c8f6057e48e9422d118ea3ef69ea9.zip |
Make sure we dont create CTARGET-VER entries in env.d #195054.
(Portage version: 2.1.3.12)
Diffstat (limited to 'sys-devel/gcc-config')
-rw-r--r-- | sys-devel/gcc-config/ChangeLog | 8 | ||||
-rw-r--r-- | sys-devel/gcc-config/files/digest-gcc-config-1.4.0-r4 | 0 | ||||
-rwxr-xr-x | sys-devel/gcc-config/files/gcc-config-1.4.0 | 8 | ||||
-rw-r--r-- | sys-devel/gcc-config/gcc-config-1.4.0-r4.ebuild | 55 |
4 files changed, 68 insertions, 3 deletions
diff --git a/sys-devel/gcc-config/ChangeLog b/sys-devel/gcc-config/ChangeLog index 6e4af78d6fee..d1e701be36ca 100644 --- a/sys-devel/gcc-config/ChangeLog +++ b/sys-devel/gcc-config/ChangeLog @@ -1,6 +1,12 @@ # ChangeLog for sys-devel/gcc-config # Copyright 1999-2007 Gentoo Foundation; Distributed under the GPL v2 -# $Header: /var/cvsroot/gentoo-x86/sys-devel/gcc-config/ChangeLog,v 1.167 2007/10/07 04:20:36 vapier Exp $ +# $Header: /var/cvsroot/gentoo-x86/sys-devel/gcc-config/ChangeLog,v 1.168 2007/10/11 05:27:56 vapier Exp $ + +*gcc-config-1.4.0-r4 (11 Oct 2007) + + 11 Oct 2007; Mike Frysinger <vapier@gentoo.org> files/gcc-config-1.4.0, + +gcc-config-1.4.0-r4.ebuild: + Make sure we dont create CTARGET-VER entries in env.d #195054. *gcc-config-1.4.0-r3 (07 Oct 2007) diff --git a/sys-devel/gcc-config/files/digest-gcc-config-1.4.0-r4 b/sys-devel/gcc-config/files/digest-gcc-config-1.4.0-r4 new file mode 100644 index 000000000000..e69de29bb2d1 --- /dev/null +++ b/sys-devel/gcc-config/files/digest-gcc-config-1.4.0-r4 diff --git a/sys-devel/gcc-config/files/gcc-config-1.4.0 b/sys-devel/gcc-config/files/gcc-config-1.4.0 index 68de99859ee8..e9dfe5d9dcbb 100755 --- a/sys-devel/gcc-config/files/gcc-config-1.4.0 +++ b/sys-devel/gcc-config/files/gcc-config-1.4.0 @@ -1,7 +1,7 @@ #!/bin/bash # Copyright 1999-2007 Gentoo Foundation # Distributed under the terms of the GNU General Public License v2 -# $Header: /var/cvsroot/gentoo-x86/sys-devel/gcc-config/files/gcc-config-1.4.0,v 1.22 2007/10/07 04:20:36 vapier Exp $ +# $Header: /var/cvsroot/gentoo-x86/sys-devel/gcc-config/files/gcc-config-1.4.0,v 1.23 2007/10/11 05:27:57 vapier Exp $ trap ":" INT QUIT TSTP @@ -265,7 +265,9 @@ switch_profile() { # Punt old files rm -f "${ENV_D}/05gcc" + rm -f "${ENV_D}/05gcc-${CTARGET}"-* rm -f "${GCC_ENV_D}/config" + rm -f "${GCC_ENV_D}/config-${CTARGET}"-* fi # Find the bin wrapper @@ -715,7 +717,9 @@ done ${SET_X} && set -x get_real_chost -CTARGET=${CTARGET:-${CC_COMP:-${REAL_CHOST}}} +[[ ${DOIT} == "get_current_profile" ]] \ + && CTARGET=${CTARGET:-${CC_COMP:-${REAL_CHOST}}} \ + || CTARGET=${CTARGET:-${REAL_CHOST}} if [[ ${DOIT} == "switch_profile" ]] && [[ -z ${CC_COMP} ]] ; then usage 1 diff --git a/sys-devel/gcc-config/gcc-config-1.4.0-r4.ebuild b/sys-devel/gcc-config/gcc-config-1.4.0-r4.ebuild new file mode 100644 index 000000000000..92f413716ca6 --- /dev/null +++ b/sys-devel/gcc-config/gcc-config-1.4.0-r4.ebuild @@ -0,0 +1,55 @@ +# Copyright 1999-2007 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 +# $Header: /var/cvsroot/gentoo-x86/sys-devel/gcc-config/gcc-config-1.4.0-r4.ebuild,v 1.1 2007/10/11 05:27:56 vapier Exp $ + +inherit flag-o-matic toolchain-funcs multilib + +# Version of .c wrapper to use +W_VER="1.5.0" + +DESCRIPTION="Utility to change the gcc compiler being used" +HOMEPAGE="http://www.gentoo.org/" +SRC_URI="" + +LICENSE="GPL-2" +SLOT="0" +KEYWORDS="~alpha ~amd64 ~arm ~hppa ~ia64 ~m68k ~mips ~ppc ~ppc64 ~s390 ~sh ~sparc ~sparc-fbsd ~x86 ~x86-fbsd" +IUSE="" + +RDEPEND="!app-admin/eselect-compiler" + +S=${WORKDIR} + +src_unpack() { + cp "${FILESDIR}"/wrapper-${W_VER}.c "${S}"/wrapper.c || die +} + +src_compile() { + strip-flags + emake CC="$(tc-getCC)" wrapper || die "compile wrapper" +} + +src_install() { + newbin "${FILESDIR}"/${PN}-${PV} ${PN} || die "install gcc-config" + sed -i \ + -e "s:PORTAGE-VERSION:${PVR}:g" \ + -e "s:GENTOO_LIBDIR:$(get_libdir):g" \ + "${D}"/usr/bin/${PN} + + exeinto /usr/$(get_libdir)/misc + newexe wrapper gcc-config || die "install wrapper" +} + +pkg_postinst() { + # Do we have a valid multi ver setup ? + if gcc-config --get-current-profile &>/dev/null ; then + # We not longer use the /usr/include/g++-v3 hacks, as + # it is not needed ... + [[ -L ${ROOT}/usr/include/g++ ]] && rm -f "${ROOT}"/usr/include/g++ + [[ -L ${ROOT}/usr/include/g++-v3 ]] && rm -f "${ROOT}"/usr/include/g++-v3 + gcc-config $(/usr/bin/gcc-config --get-current-profile) + fi + + # Make sure old versions dont exist #79062 + rm -f "${ROOT}"/usr/sbin/gcc-config +} |