From: Alexandre Oliva Date: Sun, 3 Sep 2000 21:13:13 +0000 (+0000) Subject: * tests/defs (CC): Extract from the libtool script. X-Git-Tag: multi-language-merge-point~159 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=d6c5943dd6be6d9877732eefbe6e643769d8c0d2;p=thirdparty%2Flibtool.git * tests/defs (CC): Extract from the libtool script. * tests/link.test, tests/link-2.test, tests/quote.test: Use it. --- diff --git a/ChangeLog b/ChangeLog index 1f5187690..cb5a6c2cd 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,5 +1,8 @@ 2000-09-03 Alexandre Oliva + * tests/defs (CC): Extract from the libtool script. + * tests/link.test, tests/link-2.test, tests/quote.test: Use it. + * ltmain.in (variables_saved_for_relink): Attempt to unset them instead of setting them to an empty string. diff --git a/tests/defs b/tests/defs index 2aa752fd2..971091169 100644 --- a/tests/defs +++ b/tests/defs @@ -24,6 +24,9 @@ else prefix=NONE fi +# Extract CC from the libtool configuration +eval `$libtool --config | grep '^CC='` + # See how redirections should work. case "$VERBOSE" in NO | no | 0 | "") diff --git a/tests/link-2.test b/tests/link-2.test index 33e713d09..55f360a24 100755 --- a/tests/link-2.test +++ b/tests/link-2.test @@ -18,7 +18,7 @@ non_pic_object=hell.o EOF # Try a sample link command. -linkresult=`$libtool -n --mode=link gcc -o something foo.o hell.lo` +linkresult=`$libtool -n --mode=link $CC -o something foo.o hell.lo` res=$? diff --git a/tests/link.test b/tests/link.test index 5d1000bb0..4b208487c 100755 --- a/tests/link.test +++ b/tests/link.test @@ -11,7 +11,7 @@ fi . $srcdir/defs || exit 1 # Try a sample link command. -linkresult=`$libtool -n --mode=link gcc -o gettext ../lib/libnlsut.a` +linkresult=`$libtool -n --mode=link $CC -o gettext ../lib/libnlsut.a` test $? -eq 0 || exit 1 echo "$linkresult" diff --git a/tests/quote.test b/tests/quote.test index f71ecda03..47a07e4f0 100755 --- a/tests/quote.test +++ b/tests/quote.test @@ -62,14 +62,14 @@ for mode in compile link install; do # preargs and postargs need to go through libtool unmodified. case "$mode" in compile) - preargs="gcc -c" + preargs="$CC -c" preflag= flag="-DVAR=" postargs="foo.c" ;; link) - preargs="gcc -o hell -g -O" + preargs="$CC -o hell -g -O" preflag=-Wl, flag="-someflag=" postargs="foo.o"