]> git.ipfire.org Git - thirdparty/libtool.git/commitdiff
Fix execute mode test to actually expose cwrapper failures.
authorRalf Wildenhues <Ralf.Wildenhues@gmx.de>
Sun, 16 Nov 2008 17:29:34 +0000 (18:29 +0100)
committerRalf Wildenhues <Ralf.Wildenhues@gmx.de>
Sun, 16 Nov 2008 17:29:34 +0000 (18:29 +0100)
* tests/execute-mode.at (execute mode): Actually also test the
cwrapper on the arguments.
Report by Bruno Haible.

Signed-off-by: Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
ChangeLog
tests/execute-mode.at

index 7e49432d816a4ab6e2d29e4750f6983ac3ac306b..aff79eb84f84cd5ca892530c3059f5ecd88dc49c 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,10 @@
+2008-11-16  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
+
+       Fix execute mode test to actually expose cwrapper failures.
+       * tests/execute-mode.at (execute mode): Actually also test the
+       cwrapper on the arguments.
+       Report by Bruno Haible.
+
 2008-11-15  Charles Wilson  <libtool@cwilson.fastmail.fm>
 
        Add func_win32_import_lib_p.
index acbe0810fcec2399551e1cea934a0bac3d87d558..a019e8e41e101aaa1bc59ef28c40ce2fa66b9298 100644 (file)
@@ -119,7 +119,7 @@ AT_CHECK([$LIBTOOL --mode=link $CC $CFLAGS $LDFLAGS -o liba.la -rpath $libdir li
         [], [ignore], [ignore])
 AT_CHECK([$CC $CPPFLAGS $CFLAGS -c main.c],
         [], [ignore], [ignore])
-AT_CHECK([$LIBTOOL --mode=link $CC $CFLAGS $LDFLAGS -o main main.$OBJEXT liba.la],
+AT_CHECK([$LIBTOOL --mode=link $CC $CFLAGS $LDFLAGS -o main$EXEEXT main.$OBJEXT liba.la],
         [], [ignore], [ignore])
 
 # end of preparatory blurb.
@@ -168,6 +168,9 @@ AT_CHECK([$LIBTOOL --mode=execute ./foo lt-wrapper "arg  with special chars: \$!
         [], [./lt-real
 arg  with special chars: $!&*`'()
 ])
+AT_CHECK([$LIBTOOL --mode=execute ./main$EXEEXT "arg  with special chars: \$!&*\`'()"],
+        [], [stdout])
+AT_CHECK([$FGREP 'arg  with special chars: $!&*`'\''()' stdout], [], [ignore])
 
 # We always pair two args.  The first one is never the empty string.
 arg1=
@@ -199,6 +202,11 @@ do
   AT_CHECK([$FGREP "$arg1" stdout], [], [ignore])
   AT_CHECK([$FGREP "$arg2" stdout], [], [ignore])
   AT_CHECK([test `sed -n '/^abc$/,/^xyz$/p' stdout | wc -l` -eq 4])
+  AT_CHECK([$LIBTOOL --mode=execute ./main$EXEEXT abc "$arg1" "$arg2" xyz], [], [stdout])
+  AT_CHECK([$FGREP "$arg1" stdout], [], [ignore])
+  AT_CHECK([$FGREP "$arg2" stdout], [], [ignore])
+  # Do not match EOL here, cross setups may have an extra \r here.
+  AT_CHECK([test `sed -n '/^abc/,/^xyz/p' stdout | wc -l` -eq 4])
   arg1=
 done