Re: static libs ... again

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

 



Linus Walleij wrote:
>> gcc --shared/--static.
> 
> These are real messy to use, as far as I know it is an all-or-nothing
> flag to the linker, --static really links all libs statically (if the
> static versions are available).
> 
> What one would normally like to do would be:
> gcc ... -lfoo --static -lbar --shared -lbaz
> 
> assuming switches progress from left to right to flag that one (and only
> one) library should be linked in statically.
> 
> This does not work, 

Try this (or something close to it) instead:

gcc ... -lfoo -Wl,--static -lbar -Wl,--shared -lbaz

-- Rex

-- 
fedora-extras-list mailing list
fedora-extras-list@xxxxxxxxxx
https://www.redhat.com/mailman/listinfo/fedora-extras-list

[Index of Archives]     [Fedora General Discussion]     [Fedora Art]     [Fedora Docs]     [Fedora Package Review]     [Fedora Desktop]     [Big List of Linux Books]     [Yosemite Backpacking]     [KDE Users]

  Powered by Linux