Re: Downsize Expat For Embedded System

Sebastian Pipping <[email protected]>
Newsgroups gmane.text.xml.expat.general
Message-ID <[email protected]>
Karl Waclawek wrote:
> cjliarng wrote:
>>   I need to trim the share object down to 100~150KB.
>>   So I tried the following..
>>   My platform is on linux, use gcc for expat 2.0.1.
>>   I have tried to 
>>   Add -DXML_MIN_SIZE for CFLAGS in Makefile.
>>   And #undef XML_DTD, #undef XML_NS in expat_config.h.
>>   It works and trim around 100K away.
>>   However, the output share object libexpat.so is still around 260K.
>>   Is there any thing I can do to make the .so down to around 100K?
>>   Thanks in advanced for any advise~~
>>   
> This is strange indeed. On Windows, the regular size of the Dll is about
> 148KB, without any tricks.
> Any ideas anyone?

------------------------------------------------------------
Stripping the .so file reduces the filesize from
245,563 down to 86,944 at my place and still
seems to work. I ran this command:

$ strip -s ./.libs/libexpat.so.1.5.2

In case it doesn't work after that you could try
stripping just the debug symbols with "-d" instead.



Sebastian
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.