-all_load for non-OSX?

Jonathan Wakely jwakely.gcc@gmail.com
Sun Apr 13 20:20:00 GMT 2014


On 12 April 2014 16:18, Kevin Ingwersen wrote:
> Hey.
> I need to bundle all objects from a static library into a binary. I have only worked on OS X so far and know that I can use -all_load…but what is the equivalent on Linux?

You need the --whole-archive linker option, see
https://sourceware.org/binutils/docs/ld/Options.html#index-g_t_002d_002dwhole_002darchive-265



More information about the Gcc-help mailing list