1

I've installed latest version of Raspbian onto PI1 Model B+.

My understanding is that recent versions of Raspbian come pre-bundled with java hard float version as appears to be mentioned in this article.

But it appears the soft float version has been installed as when I check dir that determines if java is hard or soft version the arm-linux-gnueabihf folder is present :

enter image description here

which according to this post indicates that this is the soft version.

Should I just re-install java myself onto Raspbian ? Can I install linux version of java onto Raspbian ? I'm attempting to install hard float version for increased performance. Is the java version installed on Raspbian customised for Pi ?

4
  • You've read that answer wrong. Ikku is saying if there is a /lib/arm-linux-gnueabihf, you have a hard float raspbian. I don't think there is even a soft float repo anymore.
    – goldilocks
    Commented Mar 25, 2015 at 16:17
  • @goldilocks your right thanks. Is the PI version of java customized for Raspbian ?
    – blue-sky
    Commented Mar 25, 2015 at 16:27
  • I believe it has to be since there aren't that many ARMv6 devices around. Also, oracle's own download page for ARM only lists a version for "Linux ARM v6/v7"; what they mean there is it is ARMv6 but ARMv7 is backward compatible with it. It is a bit odd they do not have a dedicated ARMv7 version, since there are a lot of such devices (including the Pi 2), so the fact that this exists implies the pi is a big part of the reason.
    – goldilocks
    Commented Mar 25, 2015 at 16:40
  • ...They have another page listing a version of "Java ME" targeting the pi specifically but I would not bother with that unless you find a reason, I presume it is just a stripped down JRE or something. The pi has a lot more memory than the constraints listed there.
    – goldilocks
    Commented Mar 25, 2015 at 16:42

2 Answers 2

1

which according to this post : How can I tell if I am using the hard-float or the soft-float version of Debian/Raspbian?

You've read the accepted answer there wrong. Ikku is saying if there is a /lib/arm-linux-gnueabihf, you have a hard float Raspbian. I don't think there is even a soft float repo around anymore.

There are two versions of java widely used on GNU/Linux including Raspbian, however. The default one is usually openJDK, since it is open source. The other, which usually requires a download from Oracle, is of course Oracle java. They both follow the same standard and so should be interchangeable version for version, but the Oracle one presumably has more money behind it and not surprisingly thus might generally outperform openJDK -- you'd have to look around, I'd assume various people have benchmarked this online.

In the link you included, the Pi Foundation claims Oracle definitely is better on ARM, and hence they are now including Oracle in the repos. You can check which version you have installed:

> java -version

java version "1.7.0_75"
OpenJDK Runtime Environment ...

And Oracle looks something like:

java version "1.8.0_25"
Java(TM) SE Runtime Environment
2

According to this answer, you have the hard-float version of Java. The existence of /lib/arm-linux-gnueabihf means that you have hard-float version.

All the latest Raspbian images come pre-installed with Java (hard-float version).

The hard float version will of course provide more performance since it is optimized for ARM architecture, especially for Raspberry Pi.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.