Java – Installing oracle 7 JDK on FreeBSD 10 — Wants i586, but on AMD64

freebsdjava

I need to install Oracle Java 7 on my FreeBSD 10 server but I am a bit confused.

I am using the ports, and when I do a make install in the /usr/ports/java/linux-sun-jdk17 directory I get the following:

===>  linux-sun-jdk17-7.60 You must manually fetch the J2SE SDK download for the Linux platform (jdk-7u60-linux-i586.tar.gz) from http://www.oracle.com/technetwork/java/javase/downloads/index.html, place it in /usr/ports/distfiles and then run make again.
*** Error code 1

Stop.
make: stopped in /usr/ports/java/linux-sun-jdk17

Now I understand what it wants me to do, but I am concerned that I am on a amd64 machine and it wants me to get the java package for i586.

Can anyone who has done this give me some advice here? This server needs to be rock solid and perform well.

Thanks

Best Answer

This is because you will be running the Linux version, and currently the Linux "emulator" for FreeBSD currently only supports 32bit Linux.

(I put "emulator" in quotes because it's not really an emulator, it's really just a syscall translator. And there's work to add 64bit Linux support going on, but until then only 32bit Linux binaries can be run.)

Honestly, for me, the native OpenJDK 1.7 package (built from the java/openjdk7 port) works great, so unless you have some special requirement to use the Oracle version, use OpenJDK 1.7.