2014-12-25 20:45:22http://www.cpplive.com/html/1941.html--Hits: 2150
As a developer, we have deep experience, no matter what development, in order to deploy the development environment, we often need to toss a long time, access to a lot of information to complete, and this time, the next time to another new computer to have to again, the entire deployment process remember that it is OK, if you do not remember to start again, and encountered This gfw of Android is a particularly waste of time in environments where development resources download links are blocked. So this is also my intention to write this tutorial and the source of power, I hope that you can refer to this tutorial will be able to easily after the Mac system to deploy the Android environment.
First, before deployment, we download the following resource files: 1, the Android Developer Toolkit ADT Bundle (Android Developer tools bundle)
We choose Mac OS X 64-bit, and the download link is as follows:
https://dl.google.com/android/adt/adt-bundle-Mac-x86_64-20140702.zip
Above this link direct download may be GFW interception, recommended to use Thunder New task download
Or from my share of Baidu network disk download: http://pan.baidu.com/s/1sjLl0L3
2. Android Developer Tools ADT (Android Developer tools)
The download links are as follows:
Https://dl.google.com/android/ADT-23.0.4.zip
Above this link direct download may be GFW interception, recommended to use Thunder New task download
Or from my Baidu network disk download: http://pan.baidu.com/s/1c01Zi9q
3. Android SDK
Usually the Android SDK is downloaded and managed via the Android SDK manager included with Eclipse, but the almighty GFW causes Android SDK Manager to not download the SDK at home, so everyone is either connected to the VPN with the Android SDK The manager downloads the SDK, or downloads the three most commonly used Android SDK versions I've shared, with the address: http://pan.baidu.com/s/1ntkLQ7f, select the SDK version you need to download, Currently shared to everyone has three SDK compressed files: Android-10.zip, Android-15.zip, Android-20.zip.
4. Android Local Development Kit NDK (Native Developer Kit)
We choose Mac OS X 64-bit, and the download link is as follows:
Http://dl.google.com/android/ndk/android-ndk-r10d-darwin-x86_64.bin
Above this link direct download may be GFW interception, recommended to use Thunder New task download
Or from my Baidu network disk download: HTTP://PAN.BAIDU.COM/S/1I3Y1IR7
It should be noted that only your Android app needs to install the NDK if it is used only in C or C + + code libraries, otherwise it is not downloaded
Ii. Deployment of Eclipse
1, unzip the adt-bundle-mac-x86_64-20140702.zip to any position you are accustomed to
2. After extracting, a directory named adt-bundle-mac-x86_64-20140702 is generated, and the eclipse file within the Eclipse directory is found within the adt-bundle-mac-x86_64-20140702 directory. Drag it to the dock in your Mac to quickly open eclipse
3. Unzip all downloaded versions of Android SDK compressed files (such as Android-10.zip) into the adt-bundle-mac-x86_64-20140702/sdk/platforms/directory
4. Open Eclipse, select Help->install New Software in the menu bar, and then follow the steps below:
Description: Step ② Feel free to name the software you want to install, take ADT, step ③ Find the Adt-23.0.4.zip file that you downloaded before, then click Step ④ and follow the steps as follows:
Instructions: Step ① Select the software to be installed, step ② must not check the update (because in the country because of GFW update is will be wall), then click the step ③ complete the remaining steps (click Next,accept license,finish), After the ADT is installed, you will be prompted to restart Eclipse and click OK to restart.
So far, eclipse deployment with the Android development environment is complete.
Iii. deployment of the NDK and ADB
1, unzip the Android-ndk-r10d-darwin-x86_64.bin to any location you like, will extract a directory named Android-ndk-r10
2. Open the terminal (Terminal) under the Mac and execute the "vi ~/.bash_profile" command to edit the. bash_profile file
3. Add the following two lines at the end of the. bash_profile file
Export path= $PATH:/users/trevor/android-ndk-r10
Export path= $PATH:/users/trevor/adt-bundle-mac-x86_64-20140702/sdk/platform-tools
It is clear that here I specify the NDK's decompression directory and the platform-tools directory in the directory of ADT Bundle decompression,you can replace the actual extracted directory, and finally save. Bash_profile, After restarting the terminal (Terminal), the ndk-build and ADB commands can be executed in any directory.
Deploy Android development environment under Mac attach NDK