summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMike Frysinger <vapier@gentoo.org>2007-08-31 01:42:47 +0000
committerMike Frysinger <vapier@gentoo.org>2007-08-31 01:42:47 +0000
commite56d303d790d8962dffaeefb63e0522c0a199142 (patch)
treed9bcde6938daca70b38777726765c04137d933b1 /sys-devel
parentold (diff)
downloadgentoo-2-e56d303d790d8962dffaeefb63e0522c0a199142.tar.gz
gentoo-2-e56d303d790d8962dffaeefb63e0522c0a199142.tar.bz2
gentoo-2-e56d303d790d8962dffaeefb63e0522c0a199142.zip
Rename NATIVE symlink to .NATIVE so it doesnt show up in listings and confuse people.
(Portage version: 2.1.3.7)
Diffstat (limited to 'sys-devel')
-rw-r--r--sys-devel/gcc-config/ChangeLog9
-rw-r--r--sys-devel/gcc-config/files/digest-gcc-config-1.4.0-r20
-rwxr-xr-xsys-devel/gcc-config/files/gcc-config-1.4.05
-rw-r--r--sys-devel/gcc-config/files/wrapper-1.5.0.c4
-rw-r--r--sys-devel/gcc-config/gcc-config-1.4.0-r2.ebuild55
5 files changed, 68 insertions, 5 deletions
diff --git a/sys-devel/gcc-config/ChangeLog b/sys-devel/gcc-config/ChangeLog
index cb48006bc786..3de3a14b7ab1 100644
--- a/sys-devel/gcc-config/ChangeLog
+++ b/sys-devel/gcc-config/ChangeLog
@@ -1,6 +1,13 @@
# 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.165 2007/08/26 03:21:02 vapier Exp $
+# $Header: /var/cvsroot/gentoo-x86/sys-devel/gcc-config/ChangeLog,v 1.166 2007/08/31 01:42:47 vapier Exp $
+
+*gcc-config-1.4.0-r2 (31 Aug 2007)
+
+ 31 Aug 2007; Mike Frysinger <vapier@gentoo.org> files/gcc-config-1.4.0,
+ files/wrapper-1.5.0.c, +gcc-config-1.4.0-r2.ebuild:
+ Rename NATIVE symlink to .NATIVE so it doesnt show up in listings and
+ confuse people.
*gcc-config-1.4.0-r1 (26 Aug 2007)
diff --git a/sys-devel/gcc-config/files/digest-gcc-config-1.4.0-r2 b/sys-devel/gcc-config/files/digest-gcc-config-1.4.0-r2
new file mode 100644
index 000000000000..e69de29bb2d1
--- /dev/null
+++ b/sys-devel/gcc-config/files/digest-gcc-config-1.4.0-r2
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 e8ac054b0394..9cf1b1d486b6 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.20 2007/08/26 03:21:02 vapier Exp $
+# $Header: /var/cvsroot/gentoo-x86/sys-devel/gcc-config/files/gcc-config-1.4.0,v 1.21 2007/08/31 01:42:47 vapier Exp $
trap ":" INT QUIT TSTP
@@ -260,7 +260,8 @@ switch_profile() {
echo "CURRENT=${CC_COMP}" > "${GCC_ENV_D}/config-${CTARGET}"
# Help out the gcc wrapper
- ln -sf ${CC_COMP} "${GCC_ENV_D}/NATIVE"
+ rm -f "${GCC_ENV_D}/NATIVE" "${GCC_ENV_D}/.NATIVE"
+ ln -sf ${CC_COMP} "${GCC_ENV_D}/.NATIVE"
# Punt old files
rm -f "${ENV_D}/05gcc"
diff --git a/sys-devel/gcc-config/files/wrapper-1.5.0.c b/sys-devel/gcc-config/files/wrapper-1.5.0.c
index a23149d0b363..a434a676b351 100644
--- a/sys-devel/gcc-config/files/wrapper-1.5.0.c
+++ b/sys-devel/gcc-config/files/wrapper-1.5.0.c
@@ -1,7 +1,7 @@
/*
* 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/wrapper-1.5.0.c,v 1.3 2007/08/26 03:21:02 vapier Exp $
+ * $Header: /var/cvsroot/gentoo-x86/sys-devel/gcc-config/files/wrapper-1.5.0.c,v 1.4 2007/08/31 01:42:47 vapier Exp $
* Author: Martin Schlemmer <azarah@gentoo.org>
* az's lackey: Mike Frysinger <vapier@gentoo.org>
*/
@@ -134,7 +134,7 @@ static int find_target_in_envd(struct wrapper_data *data, int cross_compile)
/* for the sake of speed, we'll keep a symlink around for
* the native compiler. #190260
*/
- snprintf(envd_file, sizeof(envd_file)-1, "/etc/env.d/gcc/NATIVE");
+ snprintf(envd_file, sizeof(envd_file)-1, "/etc/env.d/gcc/.NATIVE");
} else {
char *ctarget, *end = strrchr(data->name, '-');
if (end == NULL)
diff --git a/sys-devel/gcc-config/gcc-config-1.4.0-r2.ebuild b/sys-devel/gcc-config/gcc-config-1.4.0-r2.ebuild
new file mode 100644
index 000000000000..674324138e29
--- /dev/null
+++ b/sys-devel/gcc-config/gcc-config-1.4.0-r2.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-r2.ebuild,v 1.1 2007/08/31 01:42:47 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
+}