Java (2) -- Build and install JDK in the development environment and configure environment variables and jdk Environment Variables
1. Install JDK
Http://www.oracle.com/technetwork/java/javase/downloads/jdk8-downloads-2133151.html
The downloaded jdkis the executable file with the extension name ".exe". Just like installing the common application software, click and follow the prompts to install it. After the installation is complete, the files in the installation directory
2. Configure Environment Variables
JAVA_HOME configure the JDK installation path (my installation path is D: \ Java \ jdk1.8.0 _ 45)
Position of the JDK command file configured by PACH (bin directory)
CLASSPACH configuration class library file location (lib directory)
The JAVA_HOME and CLASSPACH environment variables are not available by default. You need to create these two variables by yourself.
Step: Right-click the computer and choose Properties = advanced system settings = Advanced> environment variable =.
1. Right-click the computer and choose Properties.
2. Click Advanced System settings
3. Go to system property settings, click the "advanced" tab, and then click the environment variable button in the lower right corner.
4. Go to environment variable settings to create and edit environment variables.
Create and set the JAVA_HOME variable. The variable value is the JDK installation path, that is, the JDK installation location on the disk (I installed it on D: \ Java \ jdk1.8.0 _ 45 ), click OK after setting.
Similarly, create and set the CLASSPACH variable. The variable value is the location of the class library file, that is, the path of the lib directory (my path is D: \ Java \ jdk1.8.0 _ 45 \ lib). Click OK.
For the PACH variable, the system already exists. You only need to edit it and configure the JDK command file location (bin directory path) to the environment variable.
Go to edit environment variables and click OK.
So far, environment variable configuration is successful.
Check whether the environment is configured successfully.
Click Start Menu = Enter cmd and press Enter.
Enter the doscommand line mode and enter java press ENTER
The following message is displayed, indicating that the configuration is successful.