Date: Tue, 25 Nov 1997 13:49:05 +0200 (IST) From: Eli Zaretskii To: Hilaire Fernandes cc: djgpp AT delorie DOT com Subject: Re: Compiled programs are HUGE! In-Reply-To: <34799CD1.62561326@iname.com> Message-ID: MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII Precedence: bulk On Mon, 24 Nov 1997, Hilaire Fernandes wrote: > > But 200k is outragous! What is going on? > > ems with DJGPP. > > The problem is just that DJGPP has to do some jobs in place of 16 bits > DOS :( > In other platform as Risc PC, a hello.c file just take ~500 bytes once > compiled with GCC :) Sorry, this might be misleading. First, in most cases the large executable is caused by the fact that people don't strip the debugging symbols (-s switch to gcc). This makes the .exe roughly 2-3 times larger (i.e., in the case above, I'd guess that stripping it will leave about 80K .exe). And second, the 500-byte executable on a Risc PC is probably produced with shared libraries, which means that the library is not linked into the program. DJGPP doesn't support this (it's hard and IMHO doesn't make much sense on DOS), and comparing statically and dynamically linked programs is meaningless. The DJGPP code indeed has to work around some deficiences in MS-DOS, but that code is relatively small and usually not linked into trivial programs. It certainly can NOT explain 200KB-long executable.