automake
[Top][All Lists]
Advanced

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

--whole-archive linker flag for certain libraries


From: Stefan Laner
Subject: --whole-archive linker flag for certain libraries
Date: Tue, 16 Jul 2013 14:13:35 +0200
User-agent: Mozilla/5.0 (Windows NT 6.1; WOW64; rv:17.0) Gecko/20130620 Thunderbird/17.0.7

Hi,

I want to build a binary with autotools. I need to have some libraries linked statically with the option --whole-archive, so I need a linker command like:

g++ -O0 -g -ggdb3 -std=c++0x -o .libs/abc abc-XY.o abc-Z.o --Wl,--whole-archive /home/.../someLib.a -Wl,--no-whole-archive /home/.../someOtherLib.so -Wl,--whole-archive /home/.../aThirdLib.a -Wl,--no-whole-archive

So I need to surround certain libraries with --Wl,--whole-archive and --Wl,--no-whole-archive, but how can I tell that to automake? If I use abc_LDADD, the command gets reorderd so that the -Wl options do not surround the librariy paths anymore.

Regards

Stefan


reply via email to

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