This procedure downloads the JDK in zip format and sets JAVA_HOME and PATH. Also, I was trying to write Java environment settings for students, but I did not use this procedure when actually guiding students. In order to prevent accidents where students who are unfamiliar with programming accidentally delete the PATH that was originally written, we decided to guide you to download in MSI format.
It's a draft, but it's a waste, so I'll publish it.
See the following site JDK (from the IT terminology dictionary that makes you feel "understood" even if you "understand" but "do not understand")
In this article, we'll set up the JDK needed to program Java on Windows to get Java working.
https://adoptopenjdk.net/releases.html?variant=openjdk11&jvmVariant=hotspot
Use the latest "jdk-11.0.5 + 10" (as of January 08, 2020) in JDK11. If you are using 64-bit Windows, select x64, and if you are using 32-bit, select x86. I'm using x64, so download it from the button below.
When you unzip the zip file, you will find a folder called "jdk-11 Honyara".
Place it locally in a suitable location.
This time
C:\Program Files\Java\jdk-11.0.5+10
Place it like this.
It is an image that looks like this when opened.
Open the control panel and open [System] as shown below. [Control Panel] → [System and Security] → [System]
If you don't know where to open the control panel, search as below.
After opening the system, click Detailed system design.
Next, click [Environment Variables (N) ...].
Did you see the following screen? On this screen, set up to use Java on Windows.
If this is your first time setting JAVA_HOME, press New.
Specify the location of the JDK11 obtained earlier. Variable name: JAVA_HOME Variable value: Location where Java is placed (up to jdk-11 Honyara)
Now press OK.
** * Please be careful not to erase the contents originally entered in the PATH. ** **
Select Path and click Edit.
The following screen will appear, so press [New].
%JAVA_HOME%\bin
Enter.
And finally, click [Up] several times to reach the top.
Press [OK]
** * Please be careful not to erase the contents originally entered in the PATH. ** ** Since I don't have Windows 8 at hand, I will explain it by displaying a similar screen on Windows 10.
Select Path and click Edit. Unlike Windows 10, the following screen will open. First of all, it is strongly recommended to save it in Notepad etc. so that you can restore it even if you accidentally delete this variable value.
Enter the following at the beginning of this variable value and press [OK].
%JAVA_HOME%\bin;
Be careful not to forget the ;
as it is often forgotten.
When there are multiple variable values, ;
is used as a delimiter.
At the command prompt, type ʻecho% JAVA_HOME%` and you will get the following:
C:\Users\hogehoge>echo %JAVA_HOME%
C:\Program Files\Java\jdk-11.0.5+10
Type java --version
at the command prompt and it will return:
C:\Users\hogehoge>java --version
openjdk 11.0.5 2019-10-15
OpenJDK Runtime Environment AdoptOpenJDK (build 11.0.5+10)
OpenJDK 64-Bit Server VM AdoptOpenJDK (build 11.0.5+10, mixed mode)
This completes the settings! Thank you for your hard work!
Recommended Posts