[C++-sig] Reduce the resulting .so file size

Niall Douglas s_sourceforge at nedprod.com
Wed Dec 29 23:36:00 CET 2004


On 29 Dec 2004 at 19:24, João Paulo Fernandes Farias wrote:

> Hi!
> 
> Thanks everyone for the answers.
> 
> So, how do I strip the file? Just a "strip file.so" does the job?

Personally I found that stripped so's won't function as loadable 
libraries properly.But then I'm not sure if that's important for a 
pure python extension module.

With the GCC visibility patch or GCC v4, simply call with -
fvisibility=hidden -fvisibility-inlines-hidden to minimise binary 
size.

Cheers,
Niall






More information about the Cplusplus-sig mailing list