AWS officially released Amazon Corretto 8 (original OpenJDK) on February 4th Articleを読みまして、試しにインストールしてみることにしました。
It will be carried out on Mac.
Download First, download the JDK from this AWS site. In my case, it's a Mac, so I chose macOS x64 "amazon-corretto-8.202.08.2-macosx-x64.pkg". DL the one that matches your OS.
Installation Double-click the DL pkg file and follow the wizard to install it. The following screen will appear, but unless you want to do something special for the time being, continue to complete without customizing anything.
Settings The thing goes into / Library / Java / JavaVirtualMachines /, but finally type the following command in the terminal to complete the installation. Also, if you want to set JAVA_HOME, specify the path displayed in the result with the export command.
#command
$ /usr/libexec/java_home --verbose
#Result output
$ Matching Java Virtual Machines (2):
1.8.0_202, x86_64: "Amazon Corretto 8" /Library/Java/JavaVirtualMachines/amazon-corretto-8.jdk/Contents/Home
#(Optional) JAVA_HOME settings
export JAVA_HOME=/Library/Java/JavaVirtualMachines/amazon-corretto-8.jdk/Contents/Home
that's all. The above is the procedure written on the AWS site, so I think it is correct. (Should the JAVA_HOME setting be written in a profile or something?)
I usually use Eclipse, so I specified this JDK in a suitable project and confirmed that it works (obviously).
It seems that Java 8 is the only official release, but 11 of them will be released. Although there are differences in the support deadline, there is also an option called Adopt Open JDK. In any case, I wonder if Java will continue to live with this.
Recommended Posts