Mail Archives: djgpp/2000/03/26/22:22:49
Damian Yerrick wrote:
>
> On Sun, 26 Mar 2000 01:27:12 +0200, "Bad Sector" <kom000 AT otenet DOT gr>
> wrote:
>
> >I saw that DJGPP creates very big files. DJGPP stores many debugging
> >info in EXE files. That is good for debugging my apps, but if i want
> >to give these apps to others they must be smaller. the question is:
> >how can i turn off this debugging info?
>
> Here's what I do:
>
> 1. Download and install UPX. http://upx.tsx.org/
> 2. Run UPX on your executables.
> c:\>upx -9 foo.exe
>
> UPX strips the debugging symbols from DJGPP/COFF executables,
> compresses what's left (code and data tables), and adds a
> decompressor stub at the beginning.
Upx is great...I have even comprerssed some of the other executables on
my system with it....but,you can get even smaller .exe's using the
-s switch AND upx.
Plain compile of a simple program......120503 bytes
With the -s switch .......58880 bytes
plain compile + upx .......34028 bytes
-s switch + upx .......34008 bytes
Its not a huge difference with this particular program
so i will try another.
Plain compile of a simple program......537804 bytes
With the -s switch ......289792 bytes
plain compile + upx ......123416 bytes
-s switch + upx ......123400 bytes
hmmmm....I thought i was making a point but it looks
like you only save a few bytes with using both...still
there are a FEW bytes saved....
I am gonna try one more thing....
Ok i tried the -s switch and the -O2 switch AND upx.
ended up with..........................119268 bytes
Now,that IS a little better...Now someone is gonna
tell me that the -O2 switch is some kind of bad thing
that i will wish i hadnt ever heard of......
Hope i helped.....
--
|"""""<`.THE PRINCE ,'>"""""""""""""""""""""""""""""""""""|
| `.`/""""""\,',' my sig is too big, |
|SEE HIS ( / \ \' SEE HIS but its really cool. |
| FACE \/<> <>\/ SMILE |
| / W \ Visit my ascii art site: |
| ,'\_|||||_/`. http://www.gtcom.net/~krogg/ascii/ |
| ,',' ||| `.`. krogg DOT no DOT to DOT spam AT gtcom DOT net |
|____<,' TIME TO DIE `.>____Remove no.to.spam to reply____|
- Raw text -