
25 Jan
2013
25 Jan
'13
10:36 a.m.
On 25/01/13 13:58, Nathan Hüsken wrote:
A simple hello world application has 1Mb in by 64 bit ubunut machine. When I stript it, is has about 750kb.
GHC statically links all its libraries by default. If you want a dynamically linked executable, use -dynamic (ensure you have the dynamic libraries built and/or installed though).
When I build a cross compiler for android (arm), the executable has a asize of about 10MB, stripped about 5MB.
That is huge, five times the size on my linux sysem.
Not sure what you mean by "five times the size on my linux system". What is 5 times larger than what? Static linking is useful when cross compiling, because it means you can just copy the binary over to the target system and run it. Cheers, Simon