Hello,
According to the book Exploring BeagleBone (Derek Molloy), the instructions to install java on BBB are as follows:
debian@beaglebone:~$ sudo update-alternatives --install /usr/bin/java java /opt/java-jdk/jdk1.8.0_261/bin/java 1
debian@beaglebone:~$ sudo update-alternatives --install /usr/bin/javac javac /opt/java-jdk/jdk1.8.0_261/bin/javac 1
Unless there was a typo, these commands don’t work: java has not been installed.
Thanks.
P.S. downloaded archive is unarchived in /opt/java-jdk
Hello,
According to the book Exploring BeagleBone (Derek Molloy), the instructions to install java on BBB are as follows:
Revision 1 or Revision 2 of the book?
debian@beaglebone:~$ sudo update-alternatives --install /usr/bin/java java /opt/java-jdk/jdk1.8.0_261/bin/java 1
debian@beaglebone:~$ sudo update-alternatives --install /usr/bin/javac javac /opt/java-jdk/jdk1.8.0_261/bin/javac 1
Unless there was a typo, these commands don't work: java has not been installed.
Thanks.
P.S. downloaded archive is unarchived in /opt/java-jdk
sudo apt install java-common ?
Ignoring "java 8", as that pre-dates Oracle merging their arm-32
branch directly into open-jdk.. So after java-8, openjdk is Oracle's
java..
So unless you absolutely need Java 8, just look at openjdk..
Regards,
Revision 1 or Revision 2 of the book?
2nd
sudo apt install java-common
Works ! Thanks.
BTW it installs “openjdk” ?
Revision 1 or Revision 2 of the book?
2nd
and as i asked that, i remembered, that book is sitting at work an hour away..
sudo apt install java-common
Works ! Thanks.
BTW it installs "openjdk" ?
OpenJDK (Open Java Development Kit)
Oracle submitted their Java 9 port for arm to OpenJDK:
https://openjdk.java.net/jeps/297
Regards,
OpenJDK (Open Java Development Kit)
With java-common I can run java files, so probably I’ll not need OpenJDK
… that book is sitting at work an hour away…
Sorry, here I didn’t understand what you mean.
OpenJDK provides /usr/bin/java
Regards,
Well … after executing instructions from “Exploring BeagleBone” and then installing java-common, java seems well installed:
debian@beaglebone:~$ ls /usr/bin/java* -l
lrwxrwxrwx 1 root root 22 Sep 4 12:46 /usr/bin/java → /etc/alternatives/java
lrwxrwxrwx 1 root root 23 Sep 4 12:48 /usr/bin/javac → /etc/alternatives/javac
debian@beaglebone:~$ java -version
java version “1.8.0_261”
Java™ SE Runtime Environment (build 1.8.0_261-b13)
Java HotSpot™ Client VM (build 25.261-b13, mixed mode)
debian@beaglebone:~$
I "think" update-alternatives just needs /usr/bin/java to exist, which
was solved by java-common..
Then it just updated the symlink when you ran it..
Regards,