diff options
author | Martin Schlemmer <azarah@gentoo.org> | 2003-04-28 02:15:16 +0000 |
---|---|---|
committer | Martin Schlemmer <azarah@gentoo.org> | 2003-04-28 02:15:16 +0000 |
commit | 3f8b999d93f57ab459bf5192391fc6a2fdb57bfb (patch) | |
tree | 01727d13c6e6dc9370e224adaad6b5e484584194 /sys-devel | |
parent | rev bump that gives ofx/hbci and new guile support (diff) | |
download | historical-3f8b999d93f57ab459bf5192391fc6a2fdb57bfb.tar.gz historical-3f8b999d93f57ab459bf5192391fc6a2fdb57bfb.tar.bz2 historical-3f8b999d93f57ab459bf5192391fc6a2fdb57bfb.zip |
fix for when portageq not in path
Diffstat (limited to 'sys-devel')
-rw-r--r-- | sys-devel/gcc-config/Manifest | 6 | ||||
-rw-r--r-- | sys-devel/gcc-config/files/digest-gcc-config-1.3.3-r1 | 0 | ||||
-rw-r--r-- | sys-devel/gcc-config/files/gcc-config-1.3.3 | 7 | ||||
-rw-r--r-- | sys-devel/gcc-config/gcc-config-1.3.3-r1.ebuild | 90 |
4 files changed, 97 insertions, 6 deletions
diff --git a/sys-devel/gcc-config/Manifest b/sys-devel/gcc-config/Manifest index 8d39d59c0bc0..606fad889a58 100644 --- a/sys-devel/gcc-config/Manifest +++ b/sys-devel/gcc-config/Manifest @@ -1,10 +1,10 @@ -MD5 f9a9324004de7c09adf0697b2536e558 ChangeLog 7390 +MD5 0edc4d4be9eb722af145001fe17ce937 ChangeLog 7390 MD5 0933e6187cc0f10fa79b8504e7a3bd0e gcc-config-1.3.0.ebuild 2110 MD5 db9be5ce1763eccd6aa5fea794198624 gcc-config-1.3.3.ebuild 2227 MD5 237a7e0aff8c90471ebe138056a1bf39 gcc-config-1.2.7.ebuild 1151 MD5 bd5d1a41047e3190e7f3697af110a4ca gcc-config-1.3.1.ebuild 2116 MD5 6452b1b7e2965406699a68f155e2f09e gcc-config-1.2.9.ebuild 2110 -MD5 db9be5ce1763eccd6aa5fea794198624 gcc-config-1.3.3-r1.ebuild 2227 +MD5 73ecbd4ea7beeccd5da488ee2a858682 gcc-config-1.3.3-r1.ebuild 2230 MD5 1fcaa8baac08be099a2e9a6db575101b gcc-config-1.3.2.ebuild 2187 MD5 089a5bea5fb05ee899513e43703d1013 gcc-config-1.3.1-r1.ebuild 2118 MD5 9b87bd79f5c7f42b0a93e944c79a89b2 files/gcc-config-1.3.0 7131 @@ -16,7 +16,7 @@ MD5 ee11abc1908b09d4ef5613f365202047 files/digest-gcc-config-1.3.0 192 MD5 44cb03b926702bd77bb7bbe84499348e files/gcc-config-1.4 11992 MD5 dbc7a76dc0e32a1b8734a44c00aa9abe files/digest-gcc-config-1.3.1 585 MD5 27740a9a29d5fa3a86a48a49da0c6a5c files/wrapper-1.4.c 5643 -MD5 bee9e4b8774d7b9a66a2f1cbebeafb66 files/gcc-config-1.3.3 8821 +MD5 75e41d204ac752b91f0d24ddaf486ee4 files/gcc-config-1.3.3 8821 MD5 5c9af84b60b56c0d51946122de783fc8 files/digest-gcc-config-1.2.7 133 MD5 8fe8bc98220d370e07b824abb03a1431 files/gcc-config-1.2.9 7131 MD5 38cdf2331e78ec65c5a18c6a73f2dc1a files/gcc-config-1.4.1 12952 diff --git a/sys-devel/gcc-config/files/digest-gcc-config-1.3.3-r1 b/sys-devel/gcc-config/files/digest-gcc-config-1.3.3-r1 new file mode 100644 index 000000000000..e69de29bb2d1 --- /dev/null +++ b/sys-devel/gcc-config/files/digest-gcc-config-1.3.3-r1 diff --git a/sys-devel/gcc-config/files/gcc-config-1.3.3 b/sys-devel/gcc-config/files/gcc-config-1.3.3 index ffa794390741..f00cb0326a3b 100644 --- a/sys-devel/gcc-config/files/gcc-config-1.3.3 +++ b/sys-devel/gcc-config/files/gcc-config-1.3.3 @@ -2,7 +2,7 @@ # Copyright 1999-2003 Gentoo Technologies, Inc. # Distributed under the terms of the GNU General Public License, v2 or later # Author: Martin Schlemmer <azarah@gentoo.org> -# $Header: /var/cvsroot/gentoo-x86/sys-devel/gcc-config/files/gcc-config-1.3.3,v 1.1 2003/04/12 18:44:22 azarah Exp $ +# $Header: /var/cvsroot/gentoo-x86/sys-devel/gcc-config/files/gcc-config-1.3.3,v 1.2 2003/04/28 02:14:30 azarah Exp $ source /etc/init.d/functions.sh || { @@ -119,9 +119,10 @@ cmd_setup() { CC_COMP="" get_real_chost() { - [ -n "$REAL_CHOST" ] && return 0 + [ -n "${REAL_CHOST}" ] && return 0 - REAL_CHOST="$(portageq envvar CHOST)" + # Use absolute path until all protage versions have portageq in /usr/bin + REAL_CHOST="$(/usr/lib/portage/bin/portageq envvar CHOST)" if [ -z "${REAL_CHOST}" ] then diff --git a/sys-devel/gcc-config/gcc-config-1.3.3-r1.ebuild b/sys-devel/gcc-config/gcc-config-1.3.3-r1.ebuild new file mode 100644 index 000000000000..c0d0b15556dd --- /dev/null +++ b/sys-devel/gcc-config/gcc-config-1.3.3-r1.ebuild @@ -0,0 +1,90 @@ +# Copyright 1999-2003 Gentoo Technologies, Inc. +# Distributed under the terms of the GNU General Public License v2 +# $Header: /var/cvsroot/gentoo-x86/sys-devel/gcc-config/gcc-config-1.3.3-r1.ebuild,v 1.1 2003/04/28 02:14:30 azarah Exp $ + +IUSE="" + +W_VER="1.4.1" + +DISABLE_GEN_GCC_WRAPPERS="yes" + +S="${WORKDIR}/${P}" +DESCRIPTION="Utility to change the gcc compiler being used." +SRC_URI="" +HOMEPAGE="http://www.gentoo.org/" + +KEYWORDS="~x86 ~ppc ~sparc ~alpha ~mips ~hppa ~arm" +SLOT="0" +LICENSE="GPL-2" + +DEPEND="virtual/glibc + >=sys-apps/portage-2.0.47-r10" # We need portageq ... + + +src_install() { + + # Setup PATH just in case ... + if /usr/bin/gcc-config --get-current-profile &> /dev/null || \ + /usr/sbin/gcc-config --get-current-profile &> /dev/null + then + if [ -x /usr/bin/gcc-config ] + then + export PATH="`/usr/bin/gcc-config --get-bin-path`:${PATH}" + else + export PATH="`/usr/sbin/gcc-config --get-bin-path`:${PATH}" + fi + fi + + einfo "Compiling wrapper..." + ${CC:-gcc} -O2 -Wall -o ${WORKDIR}/wrapper \ + ${FILESDIR}/wrapper-${W_VER}.c || die + + exeinto /usr/lib/gcc-config + doexe ${WORKDIR}/wrapper || die + + # Only setup this if we have a proper gcc version installed, else + # we will nuke the non gcc-config versions ... + if /usr/bin/gcc-config --get-current-profile &> /dev/null || \ + /usr/sbin/gcc-config --get-current-profile &> /dev/null + then + einfo "Creating wrappers for compiler tools..." + exeinto /lib + newexe ${WORKDIR}/wrapper cpp + + exeinto /usr/bin + for x in gcc cpp cc c++ g++ ${CHOST}-gcc ${CHOST}-c++ ${CHOST}-g++ + do + newexe ${WORKDIR}/wrapper ${x} + done + fi + + einfo "Adding compat symlinks..." + into /usr + dodir /usr/sbin + newbin ${FILESDIR}/${PN}-${PV} ${PN} + dosym ../bin/${PN} /usr/sbin/${PN} +} + +pkg_postinst() { + + # Do we have a valid multi ver setup ? + if ${ROOT}/usr/bin/gcc-config --get-current-profile &> /dev/null + then + # We not longer use the /usr/include/g++-v3 hacks, as + # it is not needed ... + if [ -L ${ROOT}/usr/include/g++ ] + then + rm -f ${ROOT}/usr/include/g++ + fi + if [ -L ${ROOT}/usr/include/g++-v3 ] + then + rm -f ${ROOT}/usr/include/g++-v3 + fi + + if [ ${ROOT} = "/" ] + then + /usr/bin/gcc-config $(/usr/bin/gcc-config --get-current-profile) + fi + fi +} + |