Android Studio installation and androidstudio Installation

Source: Internet
Author: User

Android Studio installation and androidstudio Installation

I. preparation tools:

1. Configure the computer java JDK Environment

JDK can be downloaded from the official website. Download the corresponding JDK according to the configuration of the computer to be installed.

Http://www.oracle.com/technetwork/java/javase/downloads/jdk8-downloads-2133151.html

Here I choose: jdk-8u25-windows-x64.exe


Note:

Java SE Development Kit 8u25
Java SE Development Kit 8u25 Demos and Samples Downloads
JavaFX Demos and Samples Downloads


The first java se Development Kit
Second java se Development Kit + example
Third javaFX Development Kit and example

First, you must configure the Java Development Environment

Ii. Install JDK

1. Install JDK and JRE. Select the installation directory.


Two installation prompts are displayed during the installation process. Jdk is installed for the first time, and jre is installed for the second time. We recommend that you install both of them in different folders in the same java folder. (Jdk and jre cannot all be installed in the root directory of the java folder. errors may occur when they are installed in the same folder ).

(1)double install jdk-8u25-windows-x64.exe.

 

(2) Click "Next" to continue.

3) Select the installation path and click Next.


The default value is drive C. I chose disk D here. Path: D: \ Java \ jdk1.8.0 _ 25 \

(4) wait until the installation is complete. Select the JRE installation path and click Next.


Disk C is selected by default.

Wait until the installation is complete.

(5) JRE Installation

(6) Select disk D here. When selecting the change, first create a folder in the hard disk. Because it is not created during the selection. Here I created a jre1.8.0 _ 25 folder.

(7) after the installation is complete, click Close.

2. Configure the system environment

Configure environment variables: Right-click "my computer" --> "advanced" --> "environment variables ".

(1) JAVA_HOME environment variable.
Purpose: it points to the jdk installation directory. Eclipse, NetBeans, Tomcat, and other software find and use the installed jdk by searching the JAVA_HOME variable.
Configuration method: click "new" in the system variables, set the variable name to JAVA_HOME, and set the variable value to the JDK installation path. (Based on your installation path)

JAVA_HOME: D: \ Java \ jdk1.8.0 _ 25

(2) CLASSPATH environment variable.

Purpose: Specify the Class search path and use the classes that have already been compiled. The premise is that you can find them, and JVM searches for classes through CLASSPTH. We need to set dt. jar and tools. jar in the lib subdirectory under the jdk installation directory to CLASSPATH. Of course, the current directory "." must also be added to this variable.
Configuration method:
Create a CLASSPATH variable with the variable value:.; % JAVA_HOME % \ lib \ tools. jar. The name of the CLASSPATH variable, either in upper or lower case. Do not forget the front and middle semicolons. The semicolon and comma must be entered in English.

CLASSPATH:.; % JAVA_HOME % \ lib \ dt. jar; % JAVA_HOME % \ lib \ tools. jar;

(3) path Environment Variable

 

Purpose: Specify the command search path. Execute the command below the I command line, for example, when javac compiles a java program, it will go to the PATH specified by the PATH variable to check whether the corresponding command program can be found. We need to add the bin directory under the jdk installation directory to the existing PATH variable. The bin directory contains frequently used executable files such as javac/java/javadoc waiting, after setting the PATH variable, You can execute tools such as javac and java in any directory.

Find the Path variable in the system variable, which is built-in to the system and does not need to be created. Double-click Path. Because the original variable value already exists, add "; % JAVA_HOME % \ bin; % JAVA_HOME % \ jre \ bin" to the existing variable ". Pay attention to the semicolon.

Path:; % JAVA_HOME % \ bin; % JAVA_HOME % \ jre \ bin

Click OK.

Iii. test environment.

 

Check whether the configuration is successful. Run cmd and enter java, javac, and java-version (there is a space between java and-version ).

 

Environment variable:
JAVA_HOME: D: \ Java \ jdk1.8.0 _ 25
CLASSPATH:.; % JAVA_HOME % \ lib \ dt. jar; % JAVA_HOME % \ lib \ tools. jar;
Path:; % JAVA_HOME % \ bin; % JAVA_HOME % \ jre \ bin

Test:
Java, javac, and java-version

2. Install Android studio.

1. Double-click the Installation File of Android studio to go to the installation page:

2. Select the installed plug-in.

 

The first is the main program of Android Studio, required.

The second is the Android SDK, which will install the Android SDK.

The third and fourth are virtual machines and virtual machine acceleration programs. If you want to use a virtual machine to debug programs on your computer, check them out.

Click next.

3. Select the installation directory of Android studio and SDK

Select the disk where you are used to installing the software. disk C does not matter. The following SDK path can also be used for configuration.

 

4. Set the maximum memory available for the virtual machine hardware accelerator

If your computer configuration is good, you can set 2 GB by default. If the configuration is compared, you can select 1 GB. Otherwise, running other software may be affected if the configuration is too large.

5. After the next step, go to the automatic installation mode.

 

If nothing happens, you will see the following interface in a short time, which indicates that the installation is successful. Start the software.

6. Open Android studio and go to the configuration page.

This is the configuration file used to import Android studio. If this is the first installation, select the last one: do not import the configuration file, and click OK.

7. After the previous step is completed, the following page will be displayed. This is how the program checks SDK updates.

 

Because of China's national conditions, if your computer cannot be FQ or hosts is not configured, it will be difficult for anyone to get stuck on this page.

We recommend that you perform the following operations:

(1) Find the idea. properties file in the bin directory under the Android Studio installation directory;

(2) append disable. android. first. run = true to the end of the file.

(3) "skip this step. If you need to update the SDK later, click the last red link in "2. Resource download" above to download the required installation package for offline configuration.

 

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.