[Top][All Lists]

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

Re: Can't build Win32 DLL that links with static libraries

From: Ralf Wildenhues
Subject: Re: Can't build Win32 DLL that links with static libraries
Date: Sun, 2 Mar 2008 10:23:36 +0100
User-agent: Mutt/1.5.17+20080114 (2008-01-14)

Hi Neil,

* Neil Roberts wrote on Sat, Mar 01, 2008 at 08:24:22PM CET:
> As I understand it, when linking a shared library libtool checks
> whether all of the dependencies are found and that they are valid
> libraries. In the old version of libtool it just did this using
> objdump which reports the same string regardless of whether the
> library it finds is static or an import library. However in the new
> version it will use func_win32_libid if the 'file' command is
> available. That function returns a different string depending on
> whether the library is static or import. The regular expression that
> is tested on this string only accepts import libraries which makes it
> imposible to link against static libraries.
> Is this intentional?

Yes, I think this was a conscious decision made by the Cygwin/MinGW
maintainers of Libtool.

> Why would you want to stop people linking against static libraries?

AFAIK for cleanliness issues.  You shouldn't do this on other systems,
so it's encouraged to also not do it on w32.

> I've attached a patch which fixes it for my by just allowing it to
> match against static libraries as well.

A similar patch has been rejected before, for these reasons.
(This isn't a rejection, but an AFAIR.  For arguing it, it
would probably help to look up previous discussions on this.)

Hope that helps.


reply via email to

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