Hi! This is fixing a testsuite issue for MSVC, and I don't need it to go in before the release. So, no rush.
The patch was previously discussed here: http://lists.gnu.org/archive/html/libtool-patches/2008-08/msg00051.html and it is on the pr-msvc-support branch as commit fbc144008bd66848111fb8ef2d7293b33957ea1a (even though that commit happened by mistake and was one of the very unpolished ones). Ok to push after the 2.4 release? (or before if Gary is ok with that) (with this patch and the other one making need_lib_prefix.at skip, there are no more fails for MSVC/MSYS. Boggle!) Cheers, Peter >From bff43a89559b2be74250d990e18b1b64ec073b3a Mon Sep 17 00:00:00 2001 From: Peter Rosin <p...@lysator.liu.se> Date: Wed, 22 Sep 2010 09:58:47 +0200 Subject: [PATCH] tests: reloadable objects do not work on MSVC, SKIP test. * libltdl/m4/libtool.m4 (_LT_LINKER_SHLIBS) [cygwin, mingw, pw32, cegcc] <cl*, reload_cmds>: Indicate that reloadable objects do not work. * tests/duplicate_conv.at: Skip last test if reloadable objects do not work. * doc/libtool.texi (libtool script contents) <reload_cmds>: Document how to indicate that reloadable objects do not work. Signed-off-by: Peter Rosin <p...@lysator.liu.se> --- ChangeLog | 11 +++++++++++ doc/libtool.texi | 3 ++- libltdl/m4/libtool.m4 | 5 +++++ tests/duplicate_conv.at | 4 ++++ 4 files changed, 22 insertions(+), 1 deletions(-) diff --git a/ChangeLog b/ChangeLog index e011a9e..7ecc325 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,14 @@ +2010-09-22 Peter Rosin <p...@lysator.liu.se> + + tests: reloadable objects do not work on MSVC, SKIP test. + * libltdl/m4/libtool.m4 (_LT_LINKER_SHLIBS) + [cygwin, mingw, pw32, cegcc] <cl*, reload_cmds>: Indicate that + reloadable objects do not work. + * tests/duplicate_conv.at: Skip last test if reloadable + objects do not work. + * doc/libtool.texi (libtool script contents) <reload_cmds>: + Document how to indicate that reloadable objects do not work. + 2010-09-21 Peter Rosin <p...@lysator.liu.se> msvc: eliminate spaces in the library search path. diff --git a/doc/libtool.texi b/doc/libtool.texi index 0d3ff7f..7688871 100644 --- a/doc/libtool.texi +++ b/doc/libtool.texi @@ -6767,7 +6767,8 @@ replaced by the toolchain format of @code{@@OUTPUT@@}. Normally disabled @defvar reload_cmds @defvarx reload_flag -Commands to create a reloadable object. +Commands to create a reloadable object. Set @code{reload_cmds} to +...@samp{false} on systems that cannot create reloadable objects. @end defvar @defvar runpath_var diff --git a/libltdl/m4/libtool.m4 b/libltdl/m4/libtool.m4 index a048b1f..d812584 100644 --- a/libltdl/m4/libtool.m4 +++ b/libltdl/m4/libtool.m4 @@ -3081,6 +3081,11 @@ case $reload_flag in esac reload_cmds='$LD$reload_flag -o $output$reload_objs' case $host_os in + cygwin* | mingw* | pw32* | cegcc*) + if test "$GCC" != yes; then + reload_cmds=false + fi + ;; darwin*) if test "$GCC" = yes; then reload_cmds='$LTCC $LTCFLAGS -nostdlib ${wl}-r -o $output$reload_objs' diff --git a/tests/duplicate_conv.at b/tests/duplicate_conv.at index 83d5144..77496d0 100644 --- a/tests/duplicate_conv.at +++ b/tests/duplicate_conv.at @@ -25,6 +25,8 @@ AT_SETUP([duplicate convenience archive names]) AT_KEYWORDS([libtool]) +eval `$LIBTOOL --config | sed -n '/^reload_cmds=/,/^$/p'` + # We create two convenience archives with the same name, and _also_ # containing an object with the same name. This is necessary to detect # the failure with both 1.5.22 and HEAD, since the latter does not (did @@ -75,6 +77,8 @@ AT_CHECK([$LIBTOOL --mode=link $CC $CFLAGS $LDFLAGS -o main$EXEEXT main.$OBJEXT LT_AT_EXEC_CHECK([./main],[0],[ignore],[ignore]) $LIBTOOL --mode=clean rm -f libcee.la +AT_CHECK([test "x$reload_cmds" = xfalse && exit 77], [1]) + # Test whether this works with reloadable objects as well. AT_CHECK([$LIBTOOL --mode=link --tag=CC $CC $CFLAGS $LDFLAGS -o cee.$OBJEXT c.lo a/liba.la b/liba.la], [0], [ignore], [ignore]) -- 1.7.1