Here is an exerpt from man whereis :
whereis - locate the binary, source, and manual page files for a command
So the second line you get contains both the binary location but also resources used by this app like the man page location, and sources...
If you want to set your
PATH, it should point to
If you want to set
JAVA_HOME in order to get a real environment development in linux, I suggest you manually maintain your java jdk.
At home, I install java's jdk in
and I make a symlink in
/usr/local/java/jdk that points to the desired jdk.
My JAVA_HOME variable always point to
Distros don't do a satisfying job to build a really good java environment for devs to my mind.