Cleaned up postinst to be a little smarter.
authorJeremy Huddleston <eradicator@gentoo.org>
Wed, 5 Oct 2005 08:24:29 +0000 (08:24 +0000)
committerJeremy Huddleston <eradicator@gentoo.org>
Wed, 5 Oct 2005 08:24:29 +0000 (08:24 +0000)
Package-Manager: portage-2.0.53_rc3

app-admin/eselect-compiler/ChangeLog
app-admin/eselect-compiler/Manifest
app-admin/eselect-compiler/eselect-compiler-2.0.0_beta2.ebuild

index 232323b3c3c935c854de485fd723c0093fd2ed9b..7f0042340ac7ba90134f40050b4f2761b5ed3034 100644 (file)
@@ -1,6 +1,10 @@
 # ChangeLog for app-admin/eselect-compiler
 # Copyright 1999-2005 Gentoo Foundation; Distributed under the GPL v2
-# $Header: /var/cvsroot/gentoo-x86/app-admin/eselect-compiler/ChangeLog,v 1.4 2005/10/03 09:14:27 eradicator Exp $
+# $Header: /var/cvsroot/gentoo-x86/app-admin/eselect-compiler/ChangeLog,v 1.5 2005/10/05 08:24:29 eradicator Exp $
+
+  05 Oct 2005; Jeremy Huddleston <eradicator@gentoo.org>
+  eselect-compiler-2.0.0_beta2.ebuild:
+  Cleaned up postinst to be a little smarter.
 
   03 Oct 2005; Jeremy Huddleston <eradicator@gentoo.org>
   -eselect-compiler-2.0.0_beta1.ebuild, eselect-compiler-2.0.0_beta2.ebuild:
index 720e031364d6735145660b55aa07cbbff926cbce..5392e7ca2cb13fc6af43da30ffbf779ce2bf9593 100644 (file)
@@ -1,14 +1,14 @@
 -----BEGIN PGP SIGNED MESSAGE-----
 Hash: SHA1
 
-MD5 567094e03359ffc1c95af7356395228d metadata.xml 162
-MD5 ce18064f86c365602498e1f7b9991ea6 ChangeLog 1072
-MD5 0ee2f241c56682826a632038b5634ab3 eselect-compiler-2.0.0_beta2.ebuild 1139
+MD5 26ab8354ce0d692d3e94c5cb8cfdc15d ChangeLog 1215
+MD5 98e03aec8bef842f5c2eb3b44f7b12c2 eselect-compiler-2.0.0_beta2.ebuild 1439
 MD5 c7cf3a3617d90adfaacc7c2c012ddfb0 files/digest-eselect-compiler-2.0.0_beta2 79
+MD5 567094e03359ffc1c95af7356395228d metadata.xml 162
 -----BEGIN PGP SIGNATURE-----
 Version: GnuPG v1.4.2 (GNU/Linux)
 
-iD8DBQFDQVhTOpjtAl+gMRURAm2+AKC3S8f7P0vhAuKyMsFJbVn89iHtXQCfS7W7
-9gUYVWxjlVPf+ycYxy4TvcI=
-=bVXA
+iD8DBQFDQ43iOpjtAl+gMRURAgMWAJ982AmRiiX1Ve/uvojslmH1HDXHFwCfaek3
+A0AsrmsZT1WKlXVHXx09IWQ=
+=dW6C
 -----END PGP SIGNATURE-----
index af4758a1234d7fa7978aed6cbe29bed759812fe1..6de0627f4f5cdc1eaa78d16bed41f8f7f4baebdb 100644 (file)
@@ -1,6 +1,6 @@
 # Copyright 1999-2005 Gentoo Foundation
 # Distributed under the terms of the GNU General Public License v2
-# $Header: /var/cvsroot/gentoo-x86/app-admin/eselect-compiler/eselect-compiler-2.0.0_beta2.ebuild,v 1.2 2005/10/03 09:14:27 eradicator Exp $
+# $Header: /var/cvsroot/gentoo-x86/app-admin/eselect-compiler/eselect-compiler-2.0.0_beta2.ebuild,v 1.3 2005/10/05 08:24:29 eradicator Exp $
 
 DESCRIPTION="Utility to configure the active toolchain compiler"
 HOMEPAGE="http://www.gentoo.org/"
@@ -19,18 +19,25 @@ IUSE=""
 RDEPEND="app-admin/eselect"
 
 pkg_postinst() {
+       # Some toolchain.eclass installed confs on amd64 had chost instead of
+       # ctarget.
+       sed -i 's:chost:ctarget:g' ${ROOT}/etc/eselect/compiler/*
+
        # Migrate from the old configs
        if [[ ! -f "${ROOT}/etc/eselect/compiler/selection.conf" ]] ; then
+               # Migrate isn't smart enough to handle the toolchain.eclass
+               # installed confs.
+               # This should be fixed before it comes out of beta and p.m.
+               rm -f ${ROOT}/etc/eselect/compiler/*.conf
                eselect compiler migrate
        fi
 
        # Update the wrappers
        eselect compiler update
 
-       sed -i 's:chost:ctarget:g' ${ROOT}/etc/eselect/compiler/*
-
-       rm -f ${ROOT}/etc/env.d/05gcc*
-       ewarn "You should source /etc/profile in your open shells."
+       if rm -f ${ROOT}/etc/env.d/05gcc* &> /dev/null ; then
+               ewarn "You should source /etc/profile in your open shells."
+       fi
 }
 
 src_install() {