public inbox for gcc-help@gcc.gnu.org
 help / color / mirror / Atom feed
* -all_load for non-OSX?
       [not found] <979446B6-1DAA-493B-A8B7-23B226F8CDB7@googlemail.com>
@ 2014-04-12 15:18 ` Kevin Ingwersen
  2014-04-13 20:20   ` Jonathan Wakely
  0 siblings, 1 reply; 2+ messages in thread
From: Kevin Ingwersen @ 2014-04-12 15:18 UTC (permalink / raw)
  To: gcc-help

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?

Kind regards, Ingwie.

^ permalink raw reply	[flat|nested] 2+ messages in thread

* Re: -all_load for non-OSX?
  2014-04-12 15:18 ` -all_load for non-OSX? Kevin Ingwersen
@ 2014-04-13 20:20   ` Jonathan Wakely
  0 siblings, 0 replies; 2+ messages in thread
From: Jonathan Wakely @ 2014-04-13 20:20 UTC (permalink / raw)
  To: Kevin Ingwersen; +Cc: gcc-help

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

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2014-04-13 20:20 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
     [not found] <979446B6-1DAA-493B-A8B7-23B226F8CDB7@googlemail.com>
2014-04-12 15:18 ` -all_load for non-OSX? Kevin Ingwersen
2014-04-13 20:20   ` Jonathan Wakely

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).