系统相关
首页 > 系统相关> > 在Ubuntu 14.04上使用eclipse设置android sdk的综合指南LTS 64位

在Ubuntu 14.04上使用eclipse设置android sdk的综合指南LTS 64位

作者:互联网

参见英文答案 > Complete Installation Guide for Android SDK / ADT Bundle on Ubuntu                                    6个
几周前我已经转移到Ubuntu了,在设置Ubuntu后,我的第一步是设置Eclipse进行android开发.我对Linux没有任何了解.我在谷歌和本网站上搜索了一个全面的指南.大多数指南适用于较旧版本的Ubuntu,大部分说明都不适用于我.因为我不是很熟悉linux所以经常我不得不重新开始使用Ubuntu的干净副本.
我发现这个guide最终使得android开发对我起作用了.

希望它也能帮助其他用户.

解决方法:

以下是在ubuntu 14.04上设置android SDK的步骤:

# ++++++++++++++++++++++++++++++
# apt-get update and upgrade
# ++++++++++++++++++++++++++++++
sudo apt-get update
sudo apt-get upgrade

# ++++++++++++++++++++++++++++++
# For development
# ++++++++++++++++++++++++++++++
sudo apt-get install build-essential

# ++++++++++++++++++++++++++++++
# Git
# ++++++++++++++++++++++++++++++
sudo apt-get install git
git --version
#git version 1.9.1

# ++++++++++++++++++++++++++++++
#  (required for adb)
# ++++++++++++++++++++++++++++++
#bash: /usr/local/android-sdk-linux/platform-tools/adb: No such file or directory
sudo apt-get install lib32z1 lib32ncurses5 lib32bz2-1.0
#adb: error while loading shared libraries: libstdc++.so.6: cannot open shared object file: No such file or directory
sudo apt-get install g++-multilib

# ++++++++++++++++++++++++++++++
# Android SDK
# ++++++++++++++++++++++++++++++
# http://developer.android.com/sdk/index.html
# DOWNLOAD FOR OTHER PLATFORMS - SDK Tools Only - Linux 32 & 64-bit
# android-sdk_r22.6.2-linux.tgz
tar zxvf android-sdk_r22.6.2-linux.tgz
mv android-sdk-linux android-sdk_r22.6.2-linux
sudo mv android-sdk_r22.6.2-linux /usr/local/
sudo ln -s /usr/local/android-sdk_r22.6.2-linux /usr/local/android-sdk-linux
echo '' >> ~/.profile
echo '# Android SDK' >> ~/.profile
echo 'export ANDROID_SDK_HOME="/usr/local/android-sdk-linux"' >> ~/.profile
echo 'export PATH="$PATH:$ANDROID_SDK_HOME/tools"' >> ~/.profile
echo 'export PATH="$PATH:$ANDROID_SDK_HOME/platform-tools"' >> ~/.profile
source ~/.profile

# ++++++++++++++++++++++++++++++
# Android NDK
# ++++++++++++++++++++++++++++++
# https://developer.android.com/tools/sdk/ndk/index.html
# Linux 64-bit (x86)
# android-ndk-r9d-linux-x86_64.tar.bz2
tar xjvf android-ndk-r9d-linux-x86_64.tar.bz2
mv android-ndk-r9d android-ndk-r9d-linux-x86_64
sudo mv android-ndk-r9d-linux-x86_64 /usr/local/
sudo ln -s /usr/local/android-ndk-r9d-linux-x86_64 /usr/local/android-ndk-linux
echo '' >> ~/.profile
echo '# Android NDK' >> ~/.profile
echo 'export ANDROID_NDK_HOME="/usr/local/android-ndk-linux"' >> ~/.profile
echo 'export PATH="$PATH:$ANDROID_NDK_HOME"' >> ~/.profile
source ~/.profile

# ++++++++++++++++++++++++++++++
# Android w/Eclipse
# ++++++++++++++++++++++++++++++

# Run android command
# android

# Android SDK Manager
#   Installed
#     Tools - Android SDK Tools 22.6.2
#   default checked
#     Tools - Android SDK Platform-tools 19.0.1
#     Tools - Android SDK Build-tools 19.0.3
#     Android 4.4.2 (API 19) All
#     Extras - Android Support Library 19.1
#   install 13 packages

# Eclipse - Help - Install New Software...
#   Name: ADT Plugin
#   Location: https://dl-ssl.google.com/android/eclipse/

#   Developer Tools, NDK Plugins

#   Eclipse restart
#   -> Android SDK "Location of the Android SDK has not been setup in the preferences" -> Close
#   -> Welcome to Android Development -> Use exsting SDKs
#   Existing Location: /usr/local/android-sdk-linux
#   -> Next -> Finish

# Confirm : Eclipse - Window - Preferences - Android

标签:android,eclipse,adt,14-04
来源: https://codeday.me/bug/20190808/1619291.html