Thread overview
Great way to decrease D executable sizes
May 25, 2004
kinghajj
May 26, 2004
Ant
May 26, 2004
Norbert Nemec
May 28, 2004
School
May 25, 2004
(Note: I'm using linux, but this should work for windows if you have 'strip.exe'
and UPX).

First, I stripped the executable (in this case, wc)

COMMAND:
strip wc

That decreased the filesize to 68% of the original (appearently, D leaves lots to strip in it's executables!)

Then, I used UPX to compress the file.

COMMAND:
upx -o wc_c wc -9

Which lowered the filesize to 28% of the original (27758 B).

So, if you've been angry ad D's larger-than-noraml executable sizes, now you can fix it ;D


May 26, 2004
On Tue, 25 May 2004 04:20:45 +0000, kinghajj wrote:

> (Note: I'm using linux, but this should work for windows if you have 'strip.exe'
> and UPX).
> 
> First, I stripped the executable (in this case, wc)
> 
> COMMAND:
> strip wc
> 
> That decreased the filesize to 68% of the original (appearently, D leaves lots to strip in it's executables!)
> 
> Then, I used UPX to compress the file.
> 
> COMMAND:
> upx -o wc_c wc -9
> 
> Which lowered the filesize to 28% of the original (27758 B).
> 
> So, if you've been angry ad D's larger-than-noraml executable sizes, now you can fix it ;D

nice. for a linux exec (leds):
original 2_832_076
striped  2_052_952
upxed      594_183 (21%)

which is smaller then the gziped version from the striped (678_043).

Ant

May 26, 2004
kinghajj wrote:

> (Note: I'm using linux, but this should work for windows if you have
> 'strip.exe' and UPX).
> 
> First, I stripped the executable (in this case, wc)
> 
> COMMAND:
> strip wc
> 
> That decreased the filesize to 68% of the original (appearently, D leaves lots to strip in it's executables!)
> 
> Then, I used UPX to compress the file.
> 
> COMMAND:
> upx -o wc_c wc -9
> 
> Which lowered the filesize to 28% of the original (27758 B).
> 
> So, if you've been angry ad D's larger-than-noraml executable sizes, now you can fix it ;D

I would assume you get similar ratios for C++ files.
May 28, 2004
Norbert Nemec wrote:
> I would assume you get similar ratios for C++ files.

but not with C files.