[Top][All Lists]

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

Re: Favoring static linking at configure time

From: Benoit Sigoure
Subject: Re: Favoring static linking at configure time
Date: Tue, 4 Dec 2007 19:36:36 +0100

On Dec 4, 2007, at 7:20 PM, Brian Dessent wrote:

Benoit Sigoure wrote:

Of course there is: -Wl,-Bstatic -lfoo -Wl,-Bdynamic

Hmm I didn't know this.  How portable is it?  I guess a gccism, but
is it even portable across versions/ports of GCC?

It doesn't really have anything to do with gcc, it's the linker that
interprets these options.  -Wl is the only part gcc sees and that has
been in gcc forever.  I'm not sure if other compilers have options for
"pass this to the linker" or not.

-B seems to be fairly portable; all of the following support it:

<GNU ld> <Solaris ld> <FreeBSD ld> <NetBSD ld> <Irix ld> <Looks like Tru64 does not>

Sounds great. Unfortunately it doesn't seem to work with MSVC... Which is one of the compilers I target. :(
I need to check whether Intel's CC supports it.

Thank you!

Benoit Sigoure aka Tsuna
EPITA Research and Development Laboratory

reply via email to

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