![]() ![]() Some Java programmes utilise the JAVA_HOME environment variable to determine the location of the Java installation. Press Enter after entering the number of the version you wish to be the default. Press to keep the current choice, or type selection number:Ī list of all installed Java versions will be displayed. * 0 /usr/lib/jvm/java-11-openjdk-armhf/bin/java 1111 auto modeġ /usr/lib/jvm/java-11-openjdk-armhf/bin/java 1111 manual modeĢ /usr/lib/jvm/java-8-openjdk-armhf/jre/bin/java 1081 manual mode The following is an example of the output: There are 2 choices for the alternative java (providing /usr/bin/java). Use the update-alternatives utility to change the default version: sudo update-alternatives -config java If your Pi has numerous Java versions loaded, use the java -version command to see which one is the default: java -version ![]() OpenJDK Client VM (build 25.212-b01, mixed mode) Configure the Default Version This is what the final product should look like: openjdk version "1.8.0_212" Print the Java version to confirm the installation: Install Java 8 if your programme requires it by typing: sudo apt update sudo apt install openjdk-8-jdk The previous Java LTS version 8, which was released in 2008, is still maintained and widely used. You have now successfully installed Java on your Raspberry Pi and are ready to use it. OpenJDK Server VM (build 11.0.5+10-post-Raspbian-1deb10u1, mixed mode) OpenJDK Runtime Environment (build 11.0.5+10-post-Raspbian-1deb10u1) This is what the final product should look like: openjdk version "11.0.5" Verify that the installation is complete by looking at the Java version: java -version To install the OpenJDK 11 JDK on your Raspberry Pi, do the following commands: sudo apt update sudo apt install default-jdk OpenJDK 11 is the default Java development and runtime on the newest Raspbian OS, which is based on Debian 10, Buster. Installing Java 11 on a Raspberry Pi is a simple process. Some Java-based apps may require a specific version of Java, so check the programme documentation for more information. If you're not sure which Java package to install, the default OpenJDK (JDK 11) version is a good place to start. ![]()
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |