libtool
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: libtool did not search ws2_32.dll


From: Kuang-Chun Cheng
Subject: Re: libtool did not search ws2_32.dll
Date: Thu, 14 Jan 2010 06:05:12 +0800

On Thu, Jan 14, 2010 at 5:49 AM, Roumen Petrov
<address@hidden> wrote:
> Kuang-Chun Cheng wrote:
>>
>> Hi,
>>
>> I'm using mingw cross compiler (with GNU autotools) under Linux to build
>> DLL.
>> One of the package I build is gnet2-2.0.8 which will link winsock library.
>> Everything is OK, the DLL is created under Linux.
>>
>> When I copy the library to WinXP and use gnet2-2.0.8 to create
>> network my app.  The libtool complain that it can't handle -lws2_32
>> and show me error message:
>>
>> *** Warning: linker path does not have real file for library -lws2_32."
>> *** I have the capability to make that library automatically link in when"
>> *** you link to this library.  But I can only do this if you have a"
>> *** shared version of the library, which you do not appear to have"
>> *** because I did check the linker path looking for a file starting"
>>
>> I try to trace what's wrong in libtool ... and found that libtool try to
>> search
>> libws2_32.dll under couple paths ... but libtool does not know the
>> real DLL is c:\windows\system32\ws2_32.dll !!
>
> cross compiler ?

Yes, it's mingw.

>
> In cross-environment import library is .../<TARGET_ALIAS>/lib/libws2_32.a
> along with other import libraries.

Yes, so under cross environment -lws2_32 is OK.
However, when I copy the compiled libraries/headers to WinXP.
The libtool some how figure out libgnet-2.0.dll.a depends on -lws2_32.a
and want to find libws2_32.dll which does not exist on WinXP.
On WinXP, it's C:\WINDOWS\system32\ws2_32.dll without "lib" prefix.

I'm using libtool 2.2.6 on Linux (SLES 11) and libtool 2.2.6b on WinXP
(MSYS + autotools I created from source)

I also use the following command to by pass libtool's internal library search
    lt_cv_deplibs_check_method=pass_all ./configure
    make

and my app compile/link and run OK.  So I guess it's libtool's problem.

Regards,
KC


>
>
>> If I copy/rename c:\windows\system32\ws2_32.dll to
>> c:\mingw\bin\libws2_32.dll
>> then everything work OK.
>>
>> Is this expected ? or a libtool bug ?
>
> Not sure what is cause of issue. The process of you copy is not clear.
> "... and use gnet2-2.0.8 to create ... ...... Warning: linker path does not
> have real file for library -lws2_32 ...." Look like issue with native build
> and missing installation of w32api dev. package.
>
>> Thanks
>> KC
>
> Roumen
>
>
> _______________________________________________
> http://lists.gnu.org/mailman/listinfo/libtool
>




reply via email to

[Prev in Thread] Current Thread [Next in Thread]