Can't install OpenJDK6 on FreeBSD 8 release

When I try to install /usr/ports/java/openjdk6/ with # sudo make install clean I get this error message:

Code:
checking for XTST... configure: error: Package requirements (x11 xext >= 1.0.99.4 xi recordproto >= 1.13.99.1 xextproto >= 7.0.99.3 inputproto) 
were not met:

Requested 'xext >= 1.0.99.4' but version of Xext is 1.0.5
Requested 'xextproto >= 7.0.99.3' but version of XExtProto is 7.0.5

Consider adjusting the PKG_CONFIG_PATH environment variable if you
installed software in a non-standard prefix.

Alternatively, you may set the environment variables XTST_CFLAGS
and XTST_LIBS to avoid the need to call pkg-config.
See the pkg-config man page for more details.

===>  Script "configure" failed unexpectedly.
Please report the problem to x11@FreeBSD.org [maintainer] and attach the
"/usr/ports/x11/libXtst/work/libXtst-1.1.0/config.log" including the output
of the failure of your make command. Also, it might be a good idea to provide
an overview of all packages installed on your system (e.g. an `ls
/var/db/pkg`).
*** Error code 1

Stop in /usr/ports/x11/libXtst.
*** Error code 1

Stop in /usr/ports/java/diablo-jdk16.
*** Error code 1

Stop in /usr/ports/java/diablo-jdk16.
*** Error code 1

Stop in /usr/ports/java/openjdk6.
*** Error code 1

Why do Java need a x11 library? What can I do to resolve this?
 
Thanks, I updated libXext and xextproto, and it worked. But when I type javac -version I see version number 1.6.0_07, is that supposed to be correct?
 
Hmm I figured it out. You have to set JAVA_HOME to the correct installation.

Code:
export JAVA_HOME=/usr/local/openjdk6
export PATH=$PATH:$JAVA_HOME/bin

Then write
Code:
java -version

openjdk version "1.6.0"
OpenJDK Runtime Environment (build 1.6.0-b19)
OpenJDK 64-Bit Server VM (build 16.0-b13, mixed mode)

Voila! :)
 
Back
Top