Why MINGW32-EGCC compiled programs so big in size?
Daniel J. Rodriksson
djr@dit.upm.es
Sun May 31 17:25:00 GMT 1998
Andrey I. Iliev wrote:
I build some program (source.cpp) using 3 different
compilers.
Here is file size of executables :
1) VC5ÃÂ ÃÂ ÃÂ ÃÂ ÃÂ ÃÂ ÃÂ ÃÂ ÃÂ ÃÂ ÃÂ ÃÂ ÃÂ ÃÂ ÃÂ ÃÂ ÃÂ ÃÂ ÃÂ ÃÂ ÃÂ ÃÂ ÃÂ ÃÂ ÃÂ ÃÂ ÃÂ ÃÂ ÃÂ ÃÂ ÃÂ
68096
2) BCC 5.02ÃÂ ÃÂ ÃÂ ÃÂ ÃÂ ÃÂ ÃÂ ÃÂ ÃÂ ÃÂ ÃÂ ÃÂ ÃÂ ÃÂ ÃÂ ÃÂ ÃÂ ÃÂ ÃÂ ÃÂ ÃÂ
69632
3) Cygnus b19ÃÂ ÃÂ ÃÂ ÃÂ ÃÂ ÃÂ ÃÂ ÃÂ ÃÂ ÃÂ ÃÂ ÃÂ ÃÂ ÃÂ ÃÂ ÃÂ ÃÂ ÃÂ
23746
4) MINGW32-EGCCÃÂ ÃÂ ÃÂ ÃÂ ÃÂ 176149 !!!
5) MINGW32-GCCÃÂ ÃÂ ÃÂ ÃÂ ÃÂ ÃÂ ÃÂ ÃÂ ÃÂ ÃÂ
26046
Can anybody explain whyÃÂ MINGW32-EGCC produce so big executable?
ÃÂ I feel it's probably because MINGW32-EGCCÃÂ link statically
some libs?
What libs and why?
All executables has been compiled with default options:
GNU GCC: gcc -o source.exe source.cpp
VC5: cl source.cpp
BCC5: bcc32 source.cpp.
The program use the following headers:
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <time.h>
#include <math.h>
I attained these results myself, but then decided to produce a C++ executable
with mingw32-gcc ( bare bones program ), and the size was that of the
mingw32-egcc c compiled program.
My guess: C++ library is always being linked into your program. I might
be
wrong of course.
Cheers
--ÃÂ
-------------------------------------------------------------|
|ÃÂ ÃÂ ÃÂ ÃÂ ÃÂ ÃÂ ÃÂ ÃÂ Remember Scotch: 'THERE CAN BE ONLY ONE'ÃÂ ÃÂ ÃÂ ÃÂ ÃÂ ÃÂ ÃÂ ÃÂ ÃÂ ÃÂ |
-------------------------------------------------------------|
| Daniel J. RodrikssonÃÂ ÃÂ ÃÂ ÃÂ ÃÂ ÃÂ | C-220,ETSI Telecomunicaciones |
| djr@dit.upm.esÃÂ ÃÂ ÃÂ ÃÂ ÃÂ ÃÂ ÃÂ ÃÂ ÃÂ ÃÂ ÃÂ ÃÂ | Avda Paraninfo S/NÃÂ ÃÂ ÃÂ ÃÂ ÃÂ ÃÂ ÃÂ ÃÂ ÃÂ ÃÂ ÃÂ |
| http://www.dit.upm.es/~djr | 28040 MadridÃÂ ÃÂ ÃÂ ÃÂ ÃÂ ÃÂ ÃÂ ÃÂ ÃÂ ÃÂ ÃÂ ÃÂ ÃÂ ÃÂ ÃÂ ÃÂ ÃÂ |
| +34-91-3367366 + ext 469ÃÂ ÃÂ | SPAINÃÂ ÃÂ ÃÂ ÃÂ ÃÂ ÃÂ ÃÂ ÃÂ ÃÂ ÃÂ ÃÂ ÃÂ ÃÂ ÃÂ ÃÂ ÃÂ ÃÂ ÃÂ ÃÂ ÃÂ ÃÂ ÃÂ ÃÂ ÃÂ |
|------------------------------------------------------------|
ÃÂ
More information about the Cygwin
mailing list