From 89819ce23bf888fa51903f552d2105d6035ec90b Mon Sep 17 00:00:00 2001 From: Peter Rosin Date: Tue, 7 Sep 2010 18:31:18 +0200 Subject: [PATCH] Adjust naming of MSVC import libraries. * libltdl/m4/libtool.m4 (_LT_SYS_DYNAMIC_LINKER) [mingw, cygwin] [pw32, cegcc] : Adjust naming of the import library from foo-.lib to foo.dll.lib, to avoid clashes with the static library for unversioned libraries. (_LT_LINKER_SHLIBS, _LT_LANG_CXX_CONFIG) [mingw, cygwin, pw32] [cegcc] : Explicitely name the import library to match the above. Signed-off-by: Peter Rosin --- ChangeLog | 9 +++++++++ libltdl/m4/libtool.m4 | 6 +++--- 2 files changed, 12 insertions(+), 3 deletions(-) diff --git a/ChangeLog b/ChangeLog index 65d0a8b09..061ca29c1 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,5 +1,14 @@ 2010-09-07 Peter Rosin + Adjust naming of MSVC import libraries. + * libltdl/m4/libtool.m4 (_LT_SYS_DYNAMIC_LINKER) [mingw, cygwin] + [pw32, cegcc] : Adjust naming of the + import library from foo-.lib to foo.dll.lib, to + avoid clashes with the static library for unversioned libraries. + (_LT_LINKER_SHLIBS, _LT_LANG_CXX_CONFIG) [mingw, cygwin, pw32] + [cegcc] : Explicitely name the import + library to match the above. + Fixup texi typo in previous. * doc/libtool.texi (libtool script content) : Add missing 'code' command. diff --git a/libltdl/m4/libtool.m4 b/libltdl/m4/libtool.m4 index ba48ce3a2..7996c34f3 100644 --- a/libltdl/m4/libtool.m4 +++ b/libltdl/m4/libtool.m4 @@ -2312,7 +2312,7 @@ m4_if([$1], [],[ # Native MSVC libname_spec='$name' soname_spec='${libname}`echo ${release} | $SED -e 's/[[.]]/-/g'`${versuffix}${shared_ext}' - library_names_spec='${libname}`echo ${release} | $SED -e 's/[[.]]/-/g'`${versuffix}.lib' + library_names_spec='${libname}.dll.lib' sys_lib_search_path_spec="$LIB" if $ECHO "$sys_lib_search_path_spec" | [$GREP ';[c-zC-Z]:/' >/dev/null]; then # It is most probably a Windows format PATH. @@ -5004,7 +5004,7 @@ _LT_EOF else sed -e 's/\\\\\\\(.*\\\\\\\)/-link\\\ -EXPORT:\\\\\\\1/' < $export_symbols > $output_objdir/$soname.exp; fi~ - $CC -o $tool_output_objdir$soname $libobjs $compiler_flags $deplibs "@$tool_output_objdir$soname.exp" -Wl,-DLL~ + $CC -o $tool_output_objdir$soname $libobjs $compiler_flags $deplibs "@$tool_output_objdir$soname.exp" -Wl,-DLL,-IMPLIB:"$tool_output_objdir$libname.dll.lib"~ linknames=' # The linker will not automatically build a static lib if we build a DLL. # _LT_TAGVAR(old_archive_from_new_cmds, $1)='true' @@ -6003,7 +6003,7 @@ if test "$_lt_caught_CXX_error" != yes; then else $SED -e 's/\\\\\\\(.*\\\\\\\)/-link\\\ -EXPORT:\\\\\\\1/' < $export_symbols > $output_objdir/$soname.exp; fi~ - $CC -o $tool_output_objdir$soname $libobjs $compiler_flags $deplibs "@$tool_output_objdir$soname.exp" -Wl,-DLL~ + $CC -o $tool_output_objdir$soname $libobjs $compiler_flags $deplibs "@$tool_output_objdir$soname.exp" -Wl,-DLL,-IMPLIB:"$tool_output_objdir$libname.dll.lib"~ linknames=' # The linker will not automatically build a static lib if we build a DLL. # _LT_TAGVAR(old_archive_from_new_cmds, $1)='true' -- 2.47.2