summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMartin Schlemmer <azarah@gentoo.org>2004-07-24 20:40:14 +0000
committerMartin Schlemmer <azarah@gentoo.org>2004-07-24 20:40:14 +0000
commit621f7eb80feeea8297423be0ad28b257f8ccf35a (patch)
tree9044052da2059f2733ec033fc31fe087f70dd7b9 /sys-devel
parentadded bluetooth sdp patch for multisync. thanks to Ronny Haryanto <rh-gentoo@... (diff)
downloadgentoo-2-621f7eb80feeea8297423be0ad28b257f8ccf35a.tar.gz
gentoo-2-621f7eb80feeea8297423be0ad28b257f8ccf35a.tar.bz2
gentoo-2-621f7eb80feeea8297423be0ad28b257f8ccf35a.zip
Some cleanup that remove use of which from ferret <james.noble@worc.ox.ac.uk>,
bug #55262.
Diffstat (limited to 'sys-devel')
-rw-r--r--sys-devel/gcc-config/ChangeLog9
-rw-r--r--sys-devel/gcc-config/Manifest48
-rw-r--r--sys-devel/gcc-config/files/digest-gcc-config-1.3.6-r10
-rwxr-xr-xsys-devel/gcc-config/files/gcc-config-1.3.621
-rw-r--r--sys-devel/gcc-config/gcc-config-1.3.6-r1.ebuild97
5 files changed, 131 insertions, 44 deletions
diff --git a/sys-devel/gcc-config/ChangeLog b/sys-devel/gcc-config/ChangeLog
index f25398ef7d17..c6b093b296ca 100644
--- a/sys-devel/gcc-config/ChangeLog
+++ b/sys-devel/gcc-config/ChangeLog
@@ -1,6 +1,13 @@
# ChangeLog for sys-devel/gcc-config
# Copyright 2002-2004 Gentoo Foundation; Distributed under the GPL v2
-# $Header: /var/cvsroot/gentoo-x86/sys-devel/gcc-config/ChangeLog,v 1.50 2004/07/02 09:32:25 eradicator Exp $
+# $Header: /var/cvsroot/gentoo-x86/sys-devel/gcc-config/ChangeLog,v 1.51 2004/07/24 20:40:14 azarah Exp $
+
+*gcc-config-1.3.6-r1 (24 Jul 2004)
+
+ 24 Jul 2004; Martin Schlemmer <azarah@gentoo.org> files/gcc-config-1.3.6,
+ +gcc-config-1.3.6-r1.ebuild:
+ Some cleanup that remove use of which from ferret <james.noble@worc.ox.ac.uk>,
+ bug #55262.
02 Jul 2004; Jeremy Huddleston <eradicator@gentoo.org>
gcc-config-1.3.3-r1.ebuild, gcc-config-1.3.3-r2.ebuild,
diff --git a/sys-devel/gcc-config/Manifest b/sys-devel/gcc-config/Manifest
index 538ac014c07e..530928ab34db 100644
--- a/sys-devel/gcc-config/Manifest
+++ b/sys-devel/gcc-config/Manifest
@@ -1,37 +1,29 @@
------BEGIN PGP SIGNED MESSAGE-----
-Hash: SHA1
-
+MD5 8ee73cb152e0efd3b7443b20ee9229b5 gcc-config-1.3.3-r2.ebuild 2182
+MD5 6885a0db3801aa33069939f36014eb49 gcc-config-1.3.6.ebuild 2621
MD5 02e83c8b9b08c45f59877f8bf2d860d5 ChangeLog 9827
MD5 088f0c7d6fc38e61da81464eb45cab6d gcc-config-1.3.3-r1.ebuild 2201
-MD5 8ee73cb152e0efd3b7443b20ee9229b5 gcc-config-1.3.3-r2.ebuild 2182
MD5 d8a914d16f1a12e8a70dbea99e456b82 gcc-config-1.3.4.ebuild 2301
MD5 9a09f8d531c582e78977dbfd96edc1f2 metadata.xml 164
-MD5 9eb40c0112df24e7899358bd77a61f1e gcc-config-1.3.5.ebuild 2191
MD5 0220f9bd49959356ec0ed4670b71e7d8 gcc-config-1.3.5-r1.ebuild 2076
-MD5 6885a0db3801aa33069939f36014eb49 gcc-config-1.3.6.ebuild 2621
-MD5 d41d8cd98f00b204e9800998ecf8427e files/digest-gcc-config-1.3.3-r1 0
-MD5 d41d8cd98f00b204e9800998ecf8427e files/digest-gcc-config-1.3.3-r2 0
-MD5 d41d8cd98f00b204e9800998ecf8427e files/digest-gcc-config-1.3.4 0
-MD5 0d2fe061cd97a1d9b6a7230f92a767a8 files/gcc-config-1.3.3 8803
-MD5 7ddbeeed76fa5f83e7b7ddabe8bad86c files/gcc-config-1.3.3-multi-ldpath 8822
-MD5 9f2d4a45319e807f73671c1cc870f012 files/gcc-config-1.3.4 8825
-MD5 9c95908dc444d2a674309696656a7a23 files/gcc-config-1.3.4-multi-ldpath 8844
-MD5 7227c7b90d3f05a802ee2cdde8edbeda files/gcc-config-1.4 11974
-MD5 1a09fa907ee2481cc44a7e888a984759 files/gcc-config-1.4.1 12935
-MD5 4788038eaa6be90b14354db23b1a01c4 files/wrapper-1.4.1.c 7297
-MD5 61a6efc018768155ade1a2259fca9f7f files/wrapper-1.4.c 5647
-MD5 b3798d14164bc9eb35cb435a5bc6cff6 files/wrapper.c 3531
+MD5 9eb40c0112df24e7899358bd77a61f1e gcc-config-1.3.5.ebuild 2191
+MD5 6885a0db3801aa33069939f36014eb49 gcc-config-1.3.6-r1.ebuild 2621
+MD5 15a653aa8910781945ce9ffa08c3d0de files/gcc-config-1.3.5-multi-ldpath 8846
MD5 d41d8cd98f00b204e9800998ecf8427e files/digest-gcc-config-1.3.5 0
+MD5 d41d8cd98f00b204e9800998ecf8427e files/digest-gcc-config-1.3.5-r1 0
+MD5 9f2d4a45319e807f73671c1cc870f012 files/gcc-config-1.3.4 8825
MD5 654c9238fad29b2bf0954df0a0f3fbe0 files/gcc-config-1.3.5 9302
-MD5 15a653aa8910781945ce9ffa08c3d0de files/gcc-config-1.3.5-multi-ldpath 8846
+MD5 d41d8cd98f00b204e9800998ecf8427e files/digest-gcc-config-1.3.4 0
+MD5 1a09fa907ee2481cc44a7e888a984759 files/gcc-config-1.4.1 12935
MD5 f86361bcf4d0511ad58831c409422559 files/wrapper-1.4.2.c 7379
-MD5 d41d8cd98f00b204e9800998ecf8427e files/digest-gcc-config-1.3.5-r1 0
+MD5 d41d8cd98f00b204e9800998ecf8427e files/digest-gcc-config-1.3.3-r2 0
+MD5 7227c7b90d3f05a802ee2cdde8edbeda files/gcc-config-1.4 11974
+MD5 ace4b16c5f0f4fd3a8ef226fc1cf1b9d files/gcc-config-1.3.6 9544
+MD5 b3798d14164bc9eb35cb435a5bc6cff6 files/wrapper.c 3531
MD5 d41d8cd98f00b204e9800998ecf8427e files/digest-gcc-config-1.3.6 0
-MD5 29679877b3b1bdf53abb93419fdcea2c files/gcc-config-1.3.6 9687
------BEGIN PGP SIGNATURE-----
-Version: GnuPG v1.2.4 (GNU/Linux)
-
-iD8DBQFA+gIKmdTrptrqvGERArOLAJ9Kg+1ljmKeC/SG5lreH815O/YfPACfUoFu
-tt7rHR1+PCDVekknNONFRYs=
-=V6Tq
------END PGP SIGNATURE-----
+MD5 d41d8cd98f00b204e9800998ecf8427e files/digest-gcc-config-1.3.3-r1 0
+MD5 9c95908dc444d2a674309696656a7a23 files/gcc-config-1.3.4-multi-ldpath 8844
+MD5 61a6efc018768155ade1a2259fca9f7f files/wrapper-1.4.c 5647
+MD5 4788038eaa6be90b14354db23b1a01c4 files/wrapper-1.4.1.c 7297
+MD5 7ddbeeed76fa5f83e7b7ddabe8bad86c files/gcc-config-1.3.3-multi-ldpath 8822
+MD5 0d2fe061cd97a1d9b6a7230f92a767a8 files/gcc-config-1.3.3 8803
+MD5 d41d8cd98f00b204e9800998ecf8427e files/digest-gcc-config-1.3.6-r1 0
diff --git a/sys-devel/gcc-config/files/digest-gcc-config-1.3.6-r1 b/sys-devel/gcc-config/files/digest-gcc-config-1.3.6-r1
new file mode 100644
index 000000000000..e69de29bb2d1
--- /dev/null
+++ b/sys-devel/gcc-config/files/digest-gcc-config-1.3.6-r1
diff --git a/sys-devel/gcc-config/files/gcc-config-1.3.6 b/sys-devel/gcc-config/files/gcc-config-1.3.6
index adc5c77cae4e..b46581803c0b 100755
--- a/sys-devel/gcc-config/files/gcc-config-1.3.6
+++ b/sys-devel/gcc-config/files/gcc-config-1.3.6
@@ -1,7 +1,7 @@
#!/bin/bash
# Copyright 1999-2004 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.3.6,v 1.2 2004/07/15 00:59:42 agriffis Exp $
+# $Header: /var/cvsroot/gentoo-x86/sys-devel/gcc-config/files/gcc-config-1.3.6,v 1.3 2004/07/24 20:40:14 azarah Exp $
# Author: Martin Schlemmer <azarah@gentoo.org>
source /etc/init.d/functions.sh || {
@@ -50,24 +50,15 @@ then
usage
fi
-HAVE_WHICH="no"
-if [ -n "$(which which 2> /dev/null)" ]
-then
- HAVE_WHICH="yes"
-fi
-
find_path() {
[ -z "$1" ] && return 0
- if [ "${HAVE_WHICH}" = "yes" ]
+ local fullpath="$(type -P $1)"
+
+ if [ -x "${fullpath}" ]
then
- local fullpath="$(which $1 2> /dev/null)"
-
- if [ -x "${fullpath}" ]
- then
- echo "${fullpath}"
- return 0
- fi
+ echo "${fullpath}"
+ return 0
fi
for x in /bin /sbin /usr/bin /usr/sbin /usr/local/bin /usr/local/sbin
diff --git a/sys-devel/gcc-config/gcc-config-1.3.6-r1.ebuild b/sys-devel/gcc-config/gcc-config-1.3.6-r1.ebuild
new file mode 100644
index 000000000000..0e36d9498434
--- /dev/null
+++ b/sys-devel/gcc-config/gcc-config-1.3.6-r1.ebuild
@@ -0,0 +1,97 @@
+# Copyright 1999-2004 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.3.6-r1.ebuild,v 1.1 2004/07/24 20:40:14 azarah Exp $
+
+# Version of .c wrapper to use
+W_VER="1.4.2"
+
+DISABLE_GEN_GCC_WRAPPERS="yes"
+
+GCC_CONFIG_BIN="${ROOT}/usr/bin/gcc-config"
+DESCRIPTION="Utility to change the gcc compiler being used."
+HOMEPAGE="http://www.gentoo.org/"
+SRC_URI=""
+
+LICENSE="GPL-2"
+SLOT="0"
+KEYWORDS="~x86 ~ppc ~sparc ~mips ~alpha ~arm ~hppa ~amd64 ~ia64 ~ppc64 ~s390"
+IUSE=""
+
+DEPEND="virtual/libc
+ >=sys-apps/portage-2.0.47-r10" # We need portageq ...
+
+pkg_setup() {
+ if [ -x "${GCC_CONFIG_BIN}" ]
+ then
+ # Make sure while we have write access that everything is setup Ok ...
+ ${GCC_CONFIG_BIN} --get-current-profile &> /dev/null
+ fi
+}
+
+src_install() {
+ local gcc_bin_path="$(${GCC_CONFIG_BIN} --get-bin-path)"
+
+ # Setup PATH just in case ...
+ if ${GCC_CONFIG_BIN} --get-current-profile &> /dev/null
+ then
+ if [ -x "${GCC_CONFIG_BIN}" ]
+ then
+ export PATH="`${GCC_CONFIG_BIN} --get-bin-path`:${PATH}"
+ else
+ export PATH="`${GCC_CONFIG_BIN} --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 ${GCC_CONFIG_BIN} --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++ f77 gcj \
+ ${CHOST}-gcc ${CHOST}-c++ ${CHOST}-g++ ${CHOST}-f77 ${CHOST}-gcj
+ do
+ # Make sure we only install wrappers for those present ...
+ [ -x "${gcc_bin_path}/${x}" -o \
+ "${x}" = "c++" -o "${x}" = "${REAL_CHOST}-c++" -o \
+ "${x}" = "cpp" -o "${x}" = "cc" ] && \
+ newexe ${WORKDIR}/wrapper ${x}
+ done
+ fi
+
+ einfo "Installing gcc-config..."
+ newbin ${FILESDIR}/${PN}-${PV} ${PN}
+ dosed "s:PORTAGE-VERSION:${PV}:" /usr/bin/${PN}
+}
+
+pkg_postinst() {
+ # Do we have a valid multi ver setup ?
+ if ${GCC_CONFIG_BIN} --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
+ ${GCC_CONFIG_BIN} $(/usr/bin/gcc-config --get-current-profile)
+ fi
+ fi
+}