From 6a5c95e6e22cb5122eea52b5b629ded3cd144e4f Mon Sep 17 00:00:00 2001 From: Ralf Wildenhues Date: Mon, 31 Jan 2005 17:26:22 +0000 Subject: [PATCH] * tests/quote.test: Match link quoting against `"$wl"', not `-Wl,'. --- ChangeLog | 4 ++++ tests/quote.test | 12 +++++++++--- 2 files changed, 13 insertions(+), 3 deletions(-) diff --git a/ChangeLog b/ChangeLog index 3f89c98d9..6bdb76ff9 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,7 @@ +2005-01-31 Ralf Wildenhues + + * tests/quote.test: Match link quoting against `"$wl"', not `-Wl,'. + 2005-01-29 Ralf Wildenhues * libtool.m4 (AC_LIBTOOL_LANG_CXX_CONFIG, AC_LIBTOOL_PROG_LD_SHLIBS) diff --git a/tests/quote.test b/tests/quote.test index e77317a61..69b8b5e8c 100755 --- a/tests/quote.test +++ b/tests/quote.test @@ -52,6 +52,9 @@ else fi fi +# Extract $wl from the libtool configuration +eval `$libtool --config | grep '^wl='` + for mode in compile link install; do $echo "== $mode mode" @@ -64,6 +67,7 @@ for mode in compile link install; do compile) preargs="$CC -c" preflag= + match_preflag= flag="-DVAR=" postargs="foo.c" ;; @@ -71,6 +75,7 @@ for mode in compile link install; do link) preargs="$CC -o hell -g -O" preflag=-Wl, + match_preflag="$wl" flag="-someflag=" postargs="foo.o" ;; @@ -78,6 +83,7 @@ for mode in compile link install; do install) preargs="install -c" preflag= + match_preflag= flag="--something=" postargs="hell /usr/local/bin/hell" ;; @@ -89,7 +95,7 @@ for mode in compile link install; do # We used to have the contents of $match in the case statement, # without an intermediate variable, but it would fail on at least # Solaris' and HP-UX's /bin/sh. Ugh! - match="$preargs ${preflag}${flag}test " + match="$preargs ${match_preflag}${flag}test " case "$result" in *"$match"*) $echo "= passed: $result" @@ -104,7 +110,7 @@ for mode in compile link install; do for mchar in \\ \" \` \$; do $echo "= trying: \\$mchar quoting" result=`$libtool -n --mode=$mode $preargs ${preflag}"${flag}${mchar}test${mchar}" $postargs` || status=1 - match="$preargs ${preflag}${flag}\\${mchar}test\\${mchar} " + match="$preargs ${match_preflag}${flag}\\${mchar}test\\${mchar} " case "$result" in *"$match"*) $echo "= passed: $result" @@ -122,7 +128,7 @@ for mode in compile link install; do $echo "= trying: \"$mchar\" quoting" result=`$libtool -n --mode=$mode $preargs ${preflag}"${flag}${mchar}test${mchar}" $postargs` || status=1 - match="$preargs ${preflag}\"${flag}${mchar}test${mchar}\" " + match="$preargs ${match_preflag}\"${flag}${mchar}test${mchar}\" " case "$result" in *"$match"*) $echo "= passed: $result" -- 2.47.3