Thanks everyone for the help. I have identified two things. The first was a 
blunder on my part; I was looking at my linked dylib in obj/local, which 
includes all the debug symbols. The ndk-build 'Install' step actually strips 
the shared lib before placing it in lib/, and this was a much more reasonable 
size.

The second thing I did was add:

LOCAL_CPPFLAGS += -fvisibility-hidden

to my Android.mk and that shrinks things a bit further too. End result is total 
of 40MB total for all 4 architectures.

Regards,
Philip Lamb

On 22/11/2012, at 9:12 PM, Jorge Izquierdo Ciges <jori...@gmail.com> wrote:

> I think Matthias is totally right. Android NDK toolchain doesn't use strip 
> when generating static libraries (it's not safe for all the cases). Usually 
> when you are compiling the final dylib that is loaded through Java the 
> toolchan uses stripping to reduze the size. but i think that it is only used 
> IF you are using the ndk-scripts. So maybe if you have set your own compile 
> configuration you didn't include that step.
> 
> More info about stripping here: 
> http://www.technovelty.org/linux/stripping-shared-libraries.html
> 
> But the simple version is that stripping a dylib is safe.
> 
_______________________________________________
osg-users mailing list
osg-users@lists.openscenegraph.org
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org

Reply via email to