Python compiled modules are too big in size (even after strip)

Antoine Pitrou solipsis at pitrou.net
Tue Apr 27 14:55:01 EDT 2010


Le Tue, 27 Apr 2010 02:43:19 -0700, King a écrit :
> 
> Python is compiled and installed successfully. However the
> modules(_socket.so, _random.so etc) are two big in terms of file size.
> They are around 4.5-5.0 mb each. I have used "strip strip-all *.so", but
> still size is around 1.5 mb each.

This is way more than it should be. Even if debug mode, most extension 
modules should be around 100kB or smaller.

> Am I missing something here? Do I have to re-configure or re-compile the
> python again from sources?

I would suggest to check the compile options gcc gets (look at "make" 
output), and try changing them.





More information about the Python-list mailing list