1.下载
- java
下载地址: http://www.oracle.com/technetwork/java/javase/downloads/jdk8-downloads-2133151.html
shell
#添加到/etc/profile
export JAVA_HOME=/usr/local/jdk1.8.0_201
export PATH=$PATH:$JAVA_HOME/bin
source /etc/profile
java -version
#添加到/etc/profile
export JAVA_HOME=/usr/local/jdk1.8.0_201
export PATH=$PATH:$JAVA_HOME/bin
source /etc/profile
java -version
- 安装Android SDK Tools
https://developer.android.com/studio/index.html
shell
#解压后会有一个tools目录
unzip sdk-tools-linux-4333796.zip -d /usr/local
export ANDROID_HOME=/usr/local/
export PATH=$PATH:$ANDROID_HOME/tools/bin
source /etc/profile
sdkmanager --list #验证环境变量配置准确
#解压后会有一个tools目录
unzip sdk-tools-linux-4333796.zip -d /usr/local
export ANDROID_HOME=/usr/local/
export PATH=$PATH:$ANDROID_HOME/tools/bin
source /etc/profile
sdkmanager --list #验证环境变量配置准确
- 安装Gradle
下载地址:https://gradle.org/gradle-download/
shell
unzip -d /usr/local gradle-5.3-bin.zip
export GRADLE_HOME=/usr/local/gradle-5.3
export PATH=$PATH:$GRADLE_HOME/bin
source /etc/profile
[root@VM_7_14_centos ~]# gradle -v
unzip -d /usr/local gradle-5.3-bin.zip
export GRADLE_HOME=/usr/local/gradle-5.3
export PATH=$PATH:$GRADLE_HOME/bin
source /etc/profile
[root@VM_7_14_centos ~]# gradle -v