A while back I promised to talk about Gump running on Kaffe.
Dims and a few of us Apache Gump people work together with Dalibor and a few other Kaffe people and try to build as much as possible on the Kaffe VM.
The problems we've solved so far
- Kopi KJC simply doesn't work for many builds
KJC is not greedy, this means it will only compile the files you tell it to compile. This is different from the JDK's javac which will also include referenced classes in the compilation if it can find them on the -sourcepath.
The first thing that failed was Ant's bootstrap script, which in turn was too cumbersome to fix - so we decided to use jikes as our Java compiler.
- GNU JAXP already implements JAXP 1.3, including DOM3
This issue is the same as building on JDK 1.5, many sources need to be changed if they want to compile with DOM3. We simply move the JAXP 1.2 stack into Kaffe's bootclasspath just like we do for JDK 1.5.
- Kaffe's class library is incomplete
and who would have thought that missing Swing methods make the JUnit compilation fail? The Kaffe/Classpath developers have been extremely busy and right now I'm not aware of any build that failed because of missing classes/signatures.
- Builds relying on com.sun.* or sun.* classes
Things that use the Base64 codec or other "undocumented secret classes" will fail when they compile or run on Kaffe. There isn't much anybody could do, except for rewriting the Sun classes or wrapping them behind reflection.
- rmic
At first Ant didn't support Kaffe's rmic (it only supports an older version in 1.6.2). This has now been fixed, but Kaffe's rmic itself doesn't work as expected. Dalibor is working on it.
- Ant doesn't support some other JDK tool alternatives coming with Kaffe
At least <native2ascii> and <javah> should now work - in CVS HEAD as well as Ant 1.6.3.
So far it has been a lot of fun to see the number of projects we managed to build in Gump increase with every hurdle we jump over. Every now and then Kaffe is broken, or I break Ant's bootstrap process for Kaffe. But the general direction is very positive. On good days we've been able to build ~25% of all projects Gump wants to build - on JDK 1.4 we manage to build ~85% of them, on JDK 1.5 ~60%.
path: /en/Apache/Gump | #