Moon Light Box

Time is Money

Linux - Install Android SDK in CentOS7 (Updated 2017-07-24)

| Comments

Updated 2017-07-24. Android SDK API/BuildTool 26 Released.

Step 1. Download and Install Android SDK.

# mkdir -p /opt/sdk-tools-linux-3859397
# cd /opt/sdk-tools-linux-3859397
# sudo wget https://dl.google.com/android/repository/sdk-tools-linux-3859397.zip
# sudo unzip sdk-tools-linux-3859397.zip
# cd /opt
# sudo chown -R root:root sdk-tools-linux-3859397
# sudo ln -s sdk-tools-linux-3859397 android-sdk

Step 2. Set Android SDK Environment Value.

# sudo vim /etc/profile.d/android-sdk-env.sh

export ANDROID_HOME="/opt/android-sdk"
export PATH="$ANDROID_HOME/tools:$ANDROID_HOME/platform-tools:$PATH"

# sudo source /etc/profile.d/android-sdk-env.sh

Step 3.1 Update Android SDK.

# cd /opt/android-sdk/tools
# sudo ./android update sdk --no-ui

Step 3.2 Update Android SDK.

Use Command Line to Update Android SDK

This is an example.
# /opt/android-sdk/tools/bin/sdkmanager --list
# /opt/android-sdk/tools/bin/sdkmanager "tools" "build-tools;26.0.0" "extras;android;m2repository" "extras;google;google_play_services" "platforms;android-26" "platform-tools"

Comments

comments powered by Disqus