Push ccache fixes into 1.3.9 as well...
authorJeremy Huddleston <eradicator@gentoo.org>
Wed, 5 Jan 2005 08:31:53 +0000 (08:31 +0000)
committerJeremy Huddleston <eradicator@gentoo.org>
Wed, 5 Jan 2005 08:31:53 +0000 (08:31 +0000)
sys-devel/gcc-config/Manifest
sys-devel/gcc-config/files/gcc-config-1.3.9

index 4f5f30eda3a53bb17ecb52c230bb84af8e5c9137..d078dca2e01fb24987629f56cc16fc9d8bb28e85 100644 (file)
@@ -1,20 +1,20 @@
 -----BEGIN PGP SIGNED MESSAGE-----
 Hash: SHA1
 
-MD5 8d1e179549c1c01e991cd0eebd80f0d8 gcc-config-1.3.9.ebuild 1371
 MD5 5d9bf515454f54cc1fa8c6f39ff6dc25 ChangeLog 14989
 MD5 4b9c47ec37e9e99b4811baaca5c1ce8f gcc-config-1.3.8-r4.ebuild 1347
+MD5 8d1e179549c1c01e991cd0eebd80f0d8 gcc-config-1.3.9.ebuild 1371
 MD5 567094e03359ffc1c95af7356395228d metadata.xml 162
-MD5 bd9ae2143c2f5ba864ec1261284d0689 files/gcc-config-1.3.8 12455
-MD5 d41d8cd98f00b204e9800998ecf8427e files/digest-gcc-config-1.3.8-r4 0
-MD5 e8a654e548e74887bcd99ed224a9efca files/gcc-config-1.3.9 12326
 MD5 7723c767ef3e4935c2299fb253412d7e files/wrapper-1.4.4.c 10132
+MD5 d41d8cd98f00b204e9800998ecf8427e files/digest-gcc-config-1.3.8-r4 0
+MD5 9b21f65b6185fb72a0d9f7b045419292 files/gcc-config-1.3.9 12404
 MD5 d41d8cd98f00b204e9800998ecf8427e files/digest-gcc-config-1.3.9 0
+MD5 bd9ae2143c2f5ba864ec1261284d0689 files/gcc-config-1.3.8 12455
 MD5 e7c7a83406a374ee4262c97d6e5673b2 files/wrapper-1.4.3.c 7545
 -----BEGIN PGP SIGNATURE-----
-Version: GnuPG v1.9.10 (GNU/Linux)
+Version: GnuPG v1.4.0 (GNU/Linux)
 
-iD8DBQFB23w1roRuSHgZdywRAp9rAKCGstjdHtW2S0dZj0l7VKZSvFVcRgCff2I5
-Yu7g/9MRU2QELM1HVXrCLlE=
-=3Aek
+iD8DBQFB26YEArHZZzCEUG0RApOaAJ9hB4fUnlQ9MPvJNGq65DTo2IipuwCfQfP/
+LY1/F7YONniyskajsbadkHg=
+=y1SZ
 -----END PGP SIGNATURE-----
index bdd75504dae273d72485ecd10089f81cdc74ab98..a481a9dd7ee76f654695db512266b41801e57220 100755 (executable)
@@ -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.9,v 1.1 2004/12/29 01:05:58 vapier Exp $
+# $Header: /var/cvsroot/gentoo-x86/sys-devel/gcc-config/files/gcc-config-1.3.9,v 1.2 2005/01/05 08:31:53 eradicator Exp $
 # Author:  Martin Schlemmer <azarah@gentoo.org>
 
 trap ":" INT QUIT TSTP
@@ -199,14 +199,16 @@ switch_profile() {
                        && ${RM} -f "${ROOT}/usr/bin/${x}"{32,64}
 
                # Only install a wrapper if the binary exists ...
-               # If installing one of the C++ binaries, check to see
-               # if g++ exists so we don't install crappy wrappers
-               if ([[ -x ${ROOT}/${GCC_BIN_PATH}/${x} || ${x} = "cc" ]]) || \
-                  ([[ ${x} = "c++" || ${x} = ${CTARGET}-c++ || ${x} = "cpp" ]] && \
-                   [[ -x ${ROOT}/${GCC_BIN_PATH}/${CTARGET}-g++ ]])
-               then
+               # We want to figure out the 'reference file' for each 
+               # wrapper (the binary we're 'wrapping') so that we can 
+               # sync mtimes together.  This makes things like ccache
+               # happy.  See Bug #70548 for more info.
+               local ref=${ROOT}/${GCC_BIN_PATH}/${x}
+               [[ ${x} = "cc" ]] && ref=${ROOT}/${GCC_BIN_PATH}/gcc
+               if [[ -x ${ref} ]] ; then
                        ${CP} -f "${ROOT}/usr/lib/gcc-config/wrapper" \
                                 "${ROOT}/usr/bin/${x}"
+                       touch -r "${ref}" "${ROOT}/usr/bin/${x}"
 
                        # Install 32bit and 64bit wrappers if need be
                        # This should probably get folded back into the wrapper ...