View Full Version: Big Binary?

ivan >>Programming >>Big Binary?


Andy- 05-01-2006
Big Binary?
Well, I've finally done it. I've managed to get IVAN to compile consistently and efficiently using mingw through the code::blocks IDE. Turns out it was linking my libraries statically without my knowing it. Now that I've got everything more or less exactly the same as the makefile, the game builds, but the binary is much larger than the stock windows binary (say, about 4.7 megs). I'm not sure why, being that I'm stripping it of all symbols and have debugging turned off, and the only library I'm linking statically is libfelib.a. Anyone have any ideas? Here's my compile line for felib: mingw32-g++.exe -ffast-math -s -mwindows -DGCC -DUSE_SDL -DWIZARD -O3 -W -fno-inline -DNDEBUG -I..\..\MinGW\include -IFeLib\Include -IC:\MinGW\include -c .\FeLib\Source\whandler.cpp -o FeLib\Release\FeLib\Source\whandler.o Here's the linking line for felib: ar.exe -r C:\Projects\ivan-0.50\FeLib\Release\libFeLib.a FeLib\Release\FeLib\Source\bitmap.o <...> FeLib\Release\FeLib\Source\whandler.o ranlib C:\Projects\ivan-0.50\FeLib\Release\libFeLib.a ar.exe: creating C:\Projects\ivan-0.50\FeLib\Release\libFeLib.a Compile line for main: windres.exe -i .\Main\Resource\Ivan.rc -J rc -o Main\Release\Main\Resource\Ivan.res -O coff -IMain\Resource -IC:\MinGW\include mingw32-g++.exe -ffast-math -s -mwindows -DGCC -DUSE_SDL -DWIZARD -O3 -DNDEBUG -I..\..\MinGW\include -IFeLib\Include -IMain\Include -IC:\MinGW\include -c .\Main\Source\actset.cpp -o Main\Release\Main\Source\actset.o Linking line for main: mingw32-g++.exe -L..\..\MinGW\lib -LFeLib\Release -LMain\Release -LC:\MinGW\lib -o C:\Projects\ivan-0.50\Main\Release\Ivan.exe Main\Release\Main\Source\actset.o Main\Release\Main\Source\areaset.o <...> Main\Release\Main\Source\wskill.o Main\Release\Main\Resource\Ivan.res FeLib\Release\libFeLib.a -lmingw32 -lSDLmain -lSDL -mwindows The binary generated from ivanmgw.mak ends up being about 2.9mb. This one ends up being about 4.7mb. The stock version is 1.9mb. Any ideas what's causing this?


Forumer™ is Voted #1 Free Forum Hosting provider
Build your own community today with the largest message board hosting company.