Annotation of /trunk/libtool/patches/libtool-1.5.22-filter-host-tags.patch
Parent Directory | Revision Log
Revision 144 -
(hide annotations)
(download)
Tue May 8 20:06:05 2007 UTC (17 years, 4 months ago) by niro
File size: 1426 byte(s)
Tue May 8 20:06:05 2007 UTC (17 years, 4 months ago) by niro
File size: 1426 byte(s)
-import
1 | niro | 144 | Make the infer tag logic a bit more magical since a lot of old packages still |
2 | exist which utilize this functionality. | ||
3 | |||
4 | http://bugs.gentoo.org/show_bug.cgi?id=77921 | ||
5 | |||
6 | --- libtool-1.5.10/ltmain.in | ||
7 | +++ libtool-1.5.10/ltmain.in | ||
8 | @@ -242,7 +242,21 @@ | ||
9 | esac | ||
10 | CC_quoted="$CC_quoted $arg" | ||
11 | done | ||
12 | + # user sometimes does CC=<HOST>-gcc so we need to match that to 'gcc' | ||
13 | + trimedcc=`echo ${CC} | $SED -e "s/${host}-//g"` | ||
14 | + # and sometimes libtool has CC=<HOST>-gcc but user does CC=gcc | ||
15 | + extendcc=${host}-${CC} | ||
16 | + # and sometimes libtool has CC=<OLDHOST>-gcc but user has CC=<NEWHOST>-gcc | ||
17 | + # (Gentoo-specific hack because we always export $CHOST) | ||
18 | + mungedcc=${CHOST-${host}}-${trimedcc} | ||
19 | case "$@ " in | ||
20 | + "cc "* | " cc "* | "${host}-cc "* | " ${host}-cc "*|\ | ||
21 | + "gcc "* | " gcc "* | "${host}-gcc "* | " ${host}-gcc "*) | ||
22 | + tagname=CC | ||
23 | + break ;; | ||
24 | + "$trimedcc "* | " $trimedcc "* | "`$echo $trimedcc` "* | " `$echo $trimedcc` "*|\ | ||
25 | + "$extendcc "* | " $extendcc "* | "`$echo $extendcc` "* | " `$echo $extendcc` "*|\ | ||
26 | + "$mungedcc "* | " $mungedcc "* | "`$echo $mungedcc` "* | " `$echo $mungedcc` "*|\ | ||
27 | " $CC "* | "$CC "* | " `$echo $CC` "* | "`$echo $CC` "* | " $CC_quoted"* | "$CC_quoted "* | " `$echo $CC_quoted` "* | "`$echo $CC_quoted` "*) | ||
28 | # The compiler in the base compile command matches | ||
29 | # the one in the tagged configuration. |