How to install openjdk-8-jdk on Debian 10 (Buster)?

后端 未结 9 1437
别跟我提以往
别跟我提以往 2020-12-23 09:06

It seems Debian does not support openjdk-8-jdk anymore due to a security issue. What is the easiest way to install openjdk-8-jdk for Debian 10 (Buster)?

9条回答
  •  悲哀的现实
    2020-12-23 10:02

    I needed to install a 32-bit version but this wasn't available at adoptopenjdk far as I could see. I tracked down a copy of a binary at java.com i their downloads area:

    jre-8u241-linux-i586.tar.gz
    

    All I needed was the JRE (rather than a JDK, but the process should be the same for either) and since it was also for a personal use only, the Oracle binary was OK (they have limitations in this regard).

    I downloaded the binary and placed it in the home folder (~/) of the user that needed to run it and then unzipped it like so:

    mkdir ~/java && cd ~/java && tar -xf jre-8u241-linux-i586.tar.gz
    

    Then added the location to the path of the user that would run the Java application by appending this line to ~/.profile:

    export PATH=$PATH:/home/youruserid/java/jre1.8.0_241/bin
    

    This worked fine for my case but there are no doubt better ways to install a binary. For example so it is available for all Unix users rather than just one.

提交回复
热议问题