From: Ralf Wildenhues Date: Sun, 16 Nov 2008 22:31:56 +0000 (+0100) Subject: Skip sys_lib_search_path on systems without libz. X-Git-Tag: v2.2.7b~173 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=44ee284ba2f235ae39460a0d372ec1ef8ac3dc34;p=thirdparty%2Flibtool.git Skip sys_lib_search_path on systems without libz. * tests/search-path.at (sys_lib_search_path): Autotest needs at least one AT_CHECK executed in a test group. So if we haven't found -lz anywhere, as may happen with cross-compilers, skip the test. * THANKS: Update. Report by Alon Bar-Lev. Signed-off-by: Ralf Wildenhues --- diff --git a/ChangeLog b/ChangeLog index aff79eb84..05285beaf 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,5 +1,13 @@ 2008-11-16 Ralf Wildenhues + Skip sys_lib_search_path on systems without libz. + * tests/search-path.at (sys_lib_search_path): Autotest needs at + least one AT_CHECK executed in a test group. So if we haven't + found -lz anywhere, as may happen with cross-compilers, skip the + test. + * THANKS: Update. + Report by Alon Bar-Lev. + Fix execute mode test to actually expose cwrapper failures. * tests/execute-mode.at (execute mode): Actually also test the cwrapper on the arguments. diff --git a/THANKS b/THANKS index 66f705b23..d37d26489 100644 --- a/THANKS +++ b/THANKS @@ -68,6 +68,7 @@ and generally assist in the libtool maintainership process: Alexei Sheplyakov varg@theor.jinr.ru + Alon Bar-Lev alon.barlev@gmail.com Andreas Schwab schwab@suse.de Andrey Slepuhin pooh@msu.ru Aneesh Kumar K.V kvaneesh@hotmail.com diff --git a/tests/search-path.at b/tests/search-path.at index 2bc56c0de..929d2dd8e 100644 --- a/tests/search-path.at +++ b/tests/search-path.at @@ -1,6 +1,6 @@ # search-path.at -- test sys_lib_search_path_spec -*- Autotest -*- # -# Copyright (C) 2006 Free Software Foundation, Inc. +# Copyright (C) 2006, 2008 Free Software Foundation, Inc. # Written by Ralf Wildenhues, 2006 # # This file is part of GNU Libtool. @@ -41,13 +41,20 @@ int main() $CC $CPPFLAGS $CFLAGS -c main.c eval `$LIBTOOL --config | $EGREP '^(sys_lib_search_path_spec)='` eval sys_lib_search_path=\"$sys_lib_search_path_spec\" +no_libz=: for path in $sys_lib_search_path; do if $LIBTOOL --mode=link $CC $CFLAGS $LDFLAGS -o main main.$OBJEXT -L$path -lz then AT_CHECK([$LIBTOOL --mode=link $CC $CFLAGS $LDFLAGS -o main main.$OBJEXT -lz], [], [ignore], [ignore]) + no_libz=false break fi done +# If -lz doesn't exist (hello, cross compiler!), we need a dummy test. +if $no_libz; then + AT_CHECK([exit 77]) +fi + AT_CLEANUP