Porting Hotspot to other platforms / OS'es
Andrew John Hughes
gnu_andrew at member.fsf.org
Wed May 21 10:04:24 PDT 2008
On 21/05/2008, Michael Neuweiler <michael at neuweiler.biz> wrote:
> I wanted to start porting OpenJDK to Syllable on Intel32 but got stuck with
> the chicken and egg problem of hotspot: "you need a running JDK to build a
> new one".
> What are your recommendations to start a port? Is cross-compiling the only
> solution or are there other ways?
> I think I saw once that an XSLT is started with an already installed
> JRE/JDK during the build process on my Linux machine. Is this the only
> reason why a JRE has to be installed?
> Any help would be greatly appreciated!
> Michael Neuweiler
(Adding distro-pkg-dev too)
My understanding, both from building OpenJDK quite a number of times
and from my own general thoughts on the issues of building a Java
environment, is that bootstrapping the JDK through its standard build
process is more than just handling XSLT.
The first thing you're likely to run across is that there are no
current Java compilers (as far as I know) that are not written in Java
-- the main two are ecj from Eclipse and javac itself. The first
thing the OpenJDK build process does is build javac and the other
language tools. The current build not only depends on an existing
javac to do this, but a full-scale JDK to run ant. My personal
feelings are that it would have been better to stick with make for the
langtools, but oh well...
If my memory serves correctly, this is followed by JAXWS and JAXP,
both of which require Java. Thus, a sensible course of action might
be to approach building HotSpot alone first. Assuming this is
possible (I have my doubts about it also including Java code), you
could then use this to run an existing JAR file containing the tools
The reason I've CCed distro-pkg-dev on this is that a lot of work on
bootstrapping on unsupported architectures (mainly the CPU rather than
the OS) has been done under the auspices of the IcedTea
(http://icedtea.classpath.org/) project. Here, we've found gcj to be
useful in breaking this bootstrapping cycle -- do you know if GCC
(which includes gcj) is available for the platform you are working on?
This might be the simplest course of action.
Looking forward to hearing how this works out for you,
Support Free Java!
Contribute to GNU Classpath and the OpenJDK
PGP Key: 94EFD9D8 (http://subkeys.pgp.net)
Fingerprint: F8EF F1EA 401E 2E60 15FA 7927 142C 2591 94EF D9D8
More information about the distro-pkg-dev