View Single Post
  #8   (View Single Post)  
Old 14th October 2008
robbak's Avatar
robbak robbak is offline
Real Name: Robert Backhaus
VPN Cryptographer
 
Join Date: May 2008
Location: North Queensland, Australia
Posts: 366
Default

For others having problems with diablo/JDK, I'll explain.

Building java is a chicken-and-egg problem. The java build process requires java. Although this sounds strange, it is a normal procedure - most C/C++ compilers are written in C/C++.

So you need a copy of java installed to build and install java.

Here is where it gets tricky. Sun, the company that holds copyrights on the java code, refuses to allow distribution of pre-compiled java binaries that have not been through their rigorous and expensive testing. While this is meant to provide a uniform java experience, it tends to provide for a uniformly annoying java experience. So, I guess it succeeds! It means that you cannot just go and grab the current JDK16 build from your nearest FreeBSD package mirror, because Sun says we cannot provide it for you.

Enter the FreeBSD Foundation. They funded the work to produce patchsets to allow java to build on FreeBSD, and funded the testing to get Sun's stamp of approval on the resultant binaries. Those binaries are the diablo ports. If you install diablo, you are getting a copy of the Sun-approved binaries.

The downside of this testing process rapidly becomes apparent. See, diablo has bugs, like all software. Normally, we'd just throw a patch in the /files directory of the port, rebuild, and the regular ports building cluster would throw a new fixed binary onto the mirrors. But we cannot do that. In order to distribute the fixed binary, we'd have to get it re-certified by Sun. So the certification procedure just ensures that a broken build (even a very slightly broken build) must remain there, causing problems.

So, the procedure is:
1. Get diablo.
2. Use diablo to build jdk16 (after manually fetching the source files, so you can click the "I agree" button. You have to agree to something, I'm not sure what. It's all thoroughly meaningless, but all part of that uniform java experience I talked about.)
3. Uninstall the broken diablo, which we never wanted in the first place.

The solution will come when Sun finally releases java under a truly Open Source license. (It will probably be GPLish, which we will have to grin and bear.) Then getting java will be a matter of a simple pkg_add command, like it should have always been.

Bitter? Not me.
__________________
The only dumb question is a question not asked.
The only dumb answer is an answer not given.
Reply With Quote