Subject: Re: Smallest program
From: [email-masked] (Ian Lance Taylor)

5 Dec 1996 16:31:59 -0800
Sender: [email-masked]
Approved: [email-masked]
Distribution: cygnus
Message-ID: <[email-masked]>
References: <c=US%a=_%p=msft%l=[email-masked]>
Original-To: [email-masked]
Original-Cc: [email-masked]
Original-Sender: [email-masked]

In cygnus.gnu-win32 [email-masked] (Alessandro Forin) writes:

>>Sent: 	Wednesday, December 04, 1996 2:30 PM
>>To: 	Alessandro Forin; Visual C++ Special Interest Group
>>Subject: 	RE: Size of smallest program
>>
>>[ Thanks to <> for reminding me of the linker options - I knew they existed I
>>just couldn't remember what they were ]
>>
>>	cl /O2 /MD /GF hello.c /link /optidata /merge:.rdata=.text
>>
>>Gives an .exe size of 2048 bytes

The GNU linker permits this sort of operation using a linker script.

You can the default linker script by running ld --verbose.  Capture
the linker script portion in a file.  Edit it.  Pass it to the linker
using the -T option.  For more information about what the GNU linker
is doing use the -M option to generate a linker map.

Ian
-
For help on using this list, send a message to
"[email-masked]" with one line of text: "help".