Minimal libjava for embedded applications?
Martin Egholm Nielsen
martin@egholm-nielsen.dk
Thu Feb 17 20:11:00 GMT 2005
Hi Joshua,
> Joshua> I was wondering if there has already been any work into making
> Joshua> a minimal libjava for use with gcj which only provides the
> Joshua> bare minimum necessary to get a basic application running.
> Nothing formal, though it has been talked about a lot.
> I know some other users omit various parts of the library from the
> build, for instance modifying the makefiles to omit all the AWT,
> Swing, etc, code.
"Honny I shrunk the libs":
http://gcc.gnu.org/ml/java/2004-07/msg00149.html
Basically I modified the "Makefile.in" for libjava to contain only the
stuff I needed, ran the special automake version Michael Koch refers to
in that thread, and rebuild libgcj.so. That made my libgcj shrink about
50%, and after "strip"'ing it, it was about 15% of the original size.
But I reckon you can make it shrink alot more if you don't need all the
Fancy Stuff (TM).
And besides that I used Dan Kegel's crosstool for handling the
parameters for the compiling the xgcj.
BR,
Martin Egholm
More information about the Java
mailing list