This is the mail archive of the
cygwin-apps@cygwin.com
mailing list for the Cygwin project.
Re: libtool devel auto-import broken
- From: Charles Wilson <cwilson at ece dot gatech dot edu>
- To: Robert Collins <robert dot collins at itdomain dot com dot au>
- Cc: CygWin-Apps <cygwin-apps at cygwin dot com>
- Date: Sun, 17 Mar 2002 04:25:21 -0500
- Subject: Re: libtool devel auto-import broken
- References: <FC169E059D1A0442A04C40F86D9BA760014BF9@itdomain003.itdomain.net.au>
Hmmm...there's a line in ltmain.sh that says:
-allow-undefined)
# FIXME: remove this flag sometime in the future.
$echo "$modename: \`-allow-undefined' is deprecated because it
is the default" 1>&2
continue
;;
Actually, libtool.m4 is an original file. It isn't generated from
anything AFAIK. Anyway, I updated to the most recent libtool CVS, and
whaddaya know -- almost all of your patches have made it in. The
attached patch is all that's left "outside" (and it also includes the
patch you just posted).
I'll whip up a new libtool-devel package soon. What's the story with
the automake-1.6 package I put up? Had a chance to play with it yet?
--Chuck
Robert Collins wrote:
> the following patch (to the created file I know, sorry short of time)
> corrects a recent regression, related to libtol tags I think, that
> prevents libtool using auto-import in some cases.
>
> Cheers,
> Rob
? .build
? .inst
? .sinst
? COPYING
? CYGWIN-PATCHES
? INSTALL
? install-sh
? missing
? mkinstalldirs
? libltdl/config-h.in
Index: libtool.m4
===================================================================
RCS file: /cvsroot/libtool/libtool/libtool.m4,v
retrieving revision 1.250
diff -u -u -r1.250 libtool.m4
--- libtool.m4 14 Mar 2002 17:40:20 -0000 1.250
+++ libtool.m4 17 Mar 2002 09:06:29 -0000
@@ -2566,7 +2566,7 @@
# _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1) is actually meaningless,
# as there is no search path for DLLs.
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
- _LT_AC_TAGVAR(allow_undefined_flag, $1)=unsupported
+ _LT_AC_TAGVAR(allow_undefined_flag, $1)=
_LT_AC_TAGVAR(always_export_symbols, $1)=yes
if $LD --help 2>&1 | egrep 'auto-import' > /dev/null; then
@@ -4366,6 +4366,9 @@
_LT_AC_TAGVAR(export_symbols_cmds, $1)='$NM -BCpg $libobjs $convenience | awk '\''{ if (((\[$]2 == "T") || (\[$]2 == "D") || (\[$]2 == "B")) && ([substr](\[$]3,1,1) != ".")) { print \[$]3 } }'\'' | sort -u > $export_symbols'
fi
;;
+ cygwin*)
+ _LT_AC_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | sed '\''s/.* //'\'' | sort | uniq > $export_symbols'
+ ;;
mingw* | pw32*)
_LT_AC_TAGVAR(export_symbols_cmds, $1)="$ltdll_cmds"
;;
Index: libltdl/ltdl.c
===================================================================
RCS file: /cvsroot/libtool/libtool/libltdl/ltdl.c,v
retrieving revision 1.163
diff -u -u -r1.163 ltdl.c
--- libltdl/ltdl.c 3 Mar 2002 03:19:55 -0000 1.163
+++ libltdl/ltdl.c 17 Mar 2002 09:06:33 -0000
@@ -911,11 +911,7 @@
/* --- DLOPEN() INTERFACE LOADER --- */
-/* Older Cygwin dlopen implementations print a spurious error message to
- stderr if the call to LoadLibrary() fails for any reason. We can
- mitigate this by not using the Cygwin implementation, and falling
- back to our own LoadLibrary() wrapper. */
-#if HAVE_LIBDL && !defined(__CYGWIN__)
+#if HAVE_LIBDL
/* dynamic linking with dlopen/dlsym */
@@ -1734,7 +1730,7 @@
handles = 0;
user_search_path = 0; /* empty search path */
-#if HAVE_LIBDL && !defined(__CYGWIN__)
+#if HAVE_LIBDL
errors += lt_dlloader_add (lt_dlloader_next (0), &sys_dl, "dlopen");
#endif
#if HAVE_SHL_LOAD
Index: mdemo/Makefile.am
===================================================================
RCS file: /cvsroot/libtool/libtool/mdemo/Makefile.am,v
retrieving revision 1.45
diff -u -u -r1.45 Makefile.am
--- mdemo/Makefile.am 3 Mar 2002 03:19:55 -0000 1.45
+++ mdemo/Makefile.am 17 Mar 2002 09:06:33 -0000
@@ -14,10 +14,10 @@
libfoo2_la_SOURCES = foo2.c
libfoo2_la_LIBADD = $(LIBM) libsub.la
-libfoo2_la_LDFLAGS = -no-undefined -module -export-symbols-regex "libfoo2.*"
+libfoo2_la_LDFLAGS = -module -export-symbols-regex "libfoo2.*"
libsub_la_SOURCES = sub.c
-libsub_la_LDFLAGS = -no-undefined
+## libsub_la_LDFLAGS = -no-undefined
noinst_HEADERS = foo.h