delorie.com/archives/browse.cgi   search  
Mail Archives: djgpp/1994/08/19/19:34:45

Date: Fri, 19 Aug 94 16:46:15 -0400
From: dj AT ctron DOT com (DJ Delorie)
To: chendi AT math DOT umbc DOT edu
Cc: djgpp AT sun DOT soe DOT clarkson DOT edu
Subject: Re: newbie question

> The output by djgpp is about 30-35k.  I read somewhere that it has 
> something to do with a -g switch.  How do I make my progs smaller?

The smallest program, in general is generated by these commands:

	gcc -O2 prog.c -o prog
	strip prog
	coff2exe prog

The smallest *possible* program is 8K (one page text, one page data)
but the mandatory startup overhead usually makes it around 24K.  Add
6K for the stub (coff2exe) to make it an .EXE.

DJ


- Raw text -


  webmaster     delorie software   privacy  
  Copyright © 2019   by DJ Delorie     Updated Jul 2019