Java on SPARC

This article is outdated: For more up to date information check the gentoo forums.

Java on SPARC/Linux has been a problem for years. But OpenJDK made it possible to compile it on SPARC. This tutorial will explain how to install java on your Gentoo/SPARC system!

Get binary icedtea SPARC ebuild
First of all, you should create an overlay as described here and create the following folder:

Then goto Bug #159780, there is a ebuild called icedtea6-bin-1.3_pre20080530.ebuild. Download this file to the folder you create before and make a static link to the original files folder of the icedtea6 binary package:

Now create a manifest file for the ebuild

unmask the binary package:

and emerge it

Congratulations! You have a running binary package for SPARC/Gentoo, which compiles nearly every java package just fine.

The only package which don't compile very well, are packages which require the com/sun/corba/se/org/omg/CORBA/ORB class, like (not-binary) icedtea6 or log4j.

Enable Java USE flag
First you probably have to create the following folder

The java useflag has been disabled in the sparc profile, so you have to "unmask" the USE flag:

Now you're able to use the USE flag as usual. Just add the "java" USE flag to a specific package in /etc/portage/package.use, or add it globally to /etc/make.conf.

Emerge icedtea6
After you have successfully installed the icedtea6 binaries, you could emerge icedtea6 packages in theory.

First of all, i really recommend you to use the java-overlay, as long as the ebuild are not in the portage tree. Be sure that you have installed Layman with the subversion USE flag before continuing.

From 6.1.6.2 < version < 6.1.9-r1 the compilation fails due to Bug 398. Be sure to use version 6.1.9-r1 or newer!

For a list of currently working/tested packages check out the gentoo-sparc mailing list.