From: Ralf Wildenhues Date: Mon, 12 Feb 2007 19:55:02 +0000 (+0000) Subject: * tests/testsuite.at (LT_AT_NOINST_EXEC_CHECK): New macro, like X-Git-Tag: release-2-1b~197 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=e3aa680f1933f757900f6ddea5e9146e89e518e4;p=thirdparty%2Flibtool.git * tests/testsuite.at (LT_AT_NOINST_EXEC_CHECK): New macro, like LT_AT_EXEC_CHECK but uses `$LIBTOOL --mode=execute' and allows to pass `-dlopen MODULE' arguments. * tests/lt_dlexit.at: Use it. Also, do not test `-dlpreopen', that currently needs library names to begin with `lib'. --- diff --git a/ChangeLog b/ChangeLog index 90ac70401..98806ea91 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,11 @@ +2007-02-12 Ralf Wildenhues + + * tests/testsuite.at (LT_AT_NOINST_EXEC_CHECK): New macro, like + LT_AT_EXEC_CHECK but uses `$LIBTOOL --mode=execute' and allows + to pass `-dlopen MODULE' arguments. + * tests/lt_dlexit.at: Use it. Also, do not test `-dlpreopen', + that currently needs library names to begin with `lib'. + 2007-02-11 Ralf Wildenhues * tests/export.at: New test: expose -export-symbols failure diff --git a/tests/lt_dlexit.at b/tests/lt_dlexit.at index a5be7c5ee..7cd51118e 100644 --- a/tests/lt_dlexit.at +++ b/tests/lt_dlexit.at @@ -129,10 +129,11 @@ AT_CHECK([$LIBTOOL --mode=link $CC $CFLAGS $LDFLAGS -o liba1.la a1.lo \ AT_CHECK([$LIBTOOL --mode=link $CC $CFLAGS $LDFLAGS -o modb1.la b1.lo \ -rpath /foo -module -avoid-version liba1.la], [], [ignore], [ignore]) -for dlopen in -dlopen -dlpreopen; do +# TODO: test -dlpreopen +for dlopen in -dlopen; do AT_CHECK([$LIBTOOL --mode=link $CC $CFLAGS $LDFLAGS -o main main.$OBJEXT \ $dlopen modb1.la $LIBLTDL], [], [ignore], [ignore]) - LT_AT_EXEC_CHECK([./main]) + LT_AT_NOINST_EXEC_CHECK([./main], [-dlopen modb1.la]) done AT_CLEANUP diff --git a/tests/testsuite.at b/tests/testsuite.at index 406030a48..37e83b4e6 100644 --- a/tests/testsuite.at +++ b/tests/testsuite.at @@ -165,6 +165,18 @@ m4_define([LT_AT_EXEC_CHECK], ]) +# LT_AT_NOINST_EXEC_CHECK(EXECUTABLE, [NOINST-MODULES], +# [STATUS = 0], [STDOUT], [STDERR]) +# --------------------------------------------------------- +m4_define([LT_AT_NOINST_EXEC_CHECK], +[AT_CHECK([$LIBTOOL --mode=execute $2 $1; lt_status=$?; + if test $lt_status -eq 0; then :; + elif test "X$host" != "X$build" && \ + { test -x "$1" || test -x "$1"$EXEEXT; } + then (exit 77); else (exit $lt_status); fi],[$3],[$4],[$5]) +]) + + # LT_AT_TAG(TAG) # -------------- m4_define([LT_AT_TAG],