Created
March 9, 2017 10:23
-
-
Save frankmanzhu/cca8662874e1f1fdb971882dd2e71ac4 to your computer and use it in GitHub Desktop.
java 8 in raspberry pi 3
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Download Oracle jdk8 | |
Log-in Raspberry Pi, enter the command to extract jdk-8-linux-arm-vfp-hflt.tar.gz to /opt directory. | |
$ sudo tar zxvf jdk-8-linux-arm-vfp-hflt.tar.gz -C /opt | |
Set default java and javac to the new installed jdk8. | |
$ sudo update-alternatives --install /usr/bin/javac javac /opt/jdk1.8.0/bin/javac 1 | |
$ sudo update-alternatives --install /usr/bin/java java /opt/jdk1.8.0/bin/java 1 | |
$ sudo update-alternatives --config javac | |
$ sudo update-alternatives --config java | |
After all, verify with the commands with -verion option. | |
$ java -version | |
$ javac -version |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment