From 3a9fabb61d02d29b74cdadbd0e74b5e89defd1c7 Mon Sep 17 00:00:00 2001 From: Peter Rosin Date: Mon, 27 Sep 2010 13:44:48 +0200 Subject: [PATCH] Skip need_lib_prefix.at on systems without lib prefix on libraries. * tests/need_lib_prefix.at [MSVC, OS/2]: Skip this test on systems that do not have libraries prefixed with lib. Signed-off-by: Peter Rosin --- ChangeLog | 4 ++++ tests/need_lib_prefix.at | 14 +++++++++++++- 2 files changed, 17 insertions(+), 1 deletion(-) diff --git a/ChangeLog b/ChangeLog index a486ac3eb..daa84fc0e 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,5 +1,9 @@ 2010-09-27 Peter Rosin + Skip need_lib_prefix.at on systems without lib prefix on libraries. + * tests/need_lib_prefix.at [MSVC, OS/2]: Skip this test on + systems that do not have libraries prefixed with lib. + tests: clean up importing and exporting on w32. Makes the touched tests pass for MSVC when DLLs are built. * tests/demo/Makefile.am, tests/pdemo/Makefile.am: Define diff --git a/tests/need_lib_prefix.at b/tests/need_lib_prefix.at index f6cfcfb35..ea36da3a5 100644 --- a/tests/need_lib_prefix.at +++ b/tests/need_lib_prefix.at @@ -1,6 +1,6 @@ # need-lib-prefix.at -- test libltdl functionality -*- Autotest -*- # -# Copyright (C) 2007, 2008 Free Software Foundation, Inc. +# Copyright (C) 2007, 2008, 2010 Free Software Foundation, Inc. # Written by Gary V. Vaughan, 2007 # # This file is part of GNU Libtool. @@ -25,6 +25,11 @@ AT_SETUP([enforced lib prefix]) AT_KEYWORDS([libltdl libtool]) +# Originally written to simulate a failure visible on systems +# which need a library prefix like 'lib', such as BeOS. Currently +# the prefix is hardcoded as 'lib', so systems that require a +# different prefix skips the test. + AT_DATA([main.c], [[#include #include @@ -148,6 +153,13 @@ esac], [], [ignore]) CPPFLAGS="$LTDLINCL $CPPFLAGS" LDFLAGS="$LDFLAGS" +# Skip this test when libraries are not normally prefixed with lib. +# E.g., for MSVC and OS/2. +eval "`$LIBTOOL --config | $EGREP '^(libname_spec)='`" +name= +eval libname=\"$libname_spec\" +AT_CHECK([test "$libname" = lib || exit 77]) + # Create our own libtool, forcing need_lib_prefix setting sed 's,^\(need_lib_prefix\)=.*$,\1=unknown,' $LIBTOOL > ./libtool LIBTOOL="$SHELL ./libtool" -- 2.47.2