android studio setup guide for mac - s3 amazonaws com

7
Android Studio Setup Guide for Mac CONTENTS (Est. Total Time Required: 60 min) Install Java (5 min) Set Your JAVA_HOME (5 min) Install Android Studio (15 min) Install Android System Images and Tools (30 min) Create an Android Virtual Device (AVD) (5 min) Intended for machines running Mac OSX Created for Developing Android Apps: Android Fundamentals

Upload: vuongdien

Post on 14-Feb-2017

231 views

Category:

Documents


2 download

TRANSCRIPT

Page 1: Android Studio Setup Guide for Mac - S3 amazonaws com

Android Studio Setup Guide for Mac

CONTENTS (Est. Total Time Required: 60 min)Install Java (5 min)Set Your JAVA_HOME (5 min)Install Android Studio (15 min)Install Android System Images and Tools (30 min)Create an Android Virtual Device (AVD) (5 min)

Intended for machines running Mac OSX Created for Developing Android Apps: Android Fundamentals

Page 2: Android Studio Setup Guide for Mac - S3 amazonaws com

Install Java

First, check if you have the Java Developer Kit (JDK) version 6.0 or greater already installed (JRE alone is not sufficient). To check if you have JDK installed (and which version), open Terminal and type javac -version. If you have Java 6.0 or greater, continue to the next slide: Set Your JAVA_HOMEIf JDK is not available or the version is lower than 6, go on to No. 2, below.

1

Navigate to the Java install page and select the latest JDK. At the time of writing, it was Java SE 8u5.2

Select the JDK for your operating system. In most cases if you have a machine purchased in the last few years, you should choose the x64 (64-bit) version. Search online for instructions to locate this information if you are not sure. Accept the license agreement to download and locate the file, and double click it to begin the installation process.

3

Page 3: Android Studio Setup Guide for Mac - S3 amazonaws com

Set Your JAVA_HOMEClick here for a doc you can copy/paste from

Go into Terminal, and open a new window1

2

Enter these two lines of code into the text editor window:

Enter this line of code in the window after the $:

open -a TextEdit ~/.bash_profile

Press enter. A text editor window named .bash_profile will appear over the Terminal window you were typing in. There may be a bunch of stuff in there. That is OK.

3

export JAVA_HOME=$(/usr/libexec/java_home)export JDK_HOME=$(/usr/libexec/java_home)

Save and Close the file.

4Return to the original Terminal window and enter this line of code:source ~/.bash_profile

Press enter to load the new environment variables. Don’t be alarmed if nothing happens -- this is normal.

Great!! You can move on to Install Android Studio

Page 4: Android Studio Setup Guide for Mac - S3 amazonaws com

Install Android Studio

Navigate to the Android developers site to install Android Studio. This page will automatically detect your operating system.Make sure to read the known issues associated with your operating system.

1

Accept the terms and conditions to start the download. Double-click the downloaded file and follow all the prompts.

2

Page 5: Android Studio Setup Guide for Mac - S3 amazonaws com

Install Android System Images & ToolsOpen Android Studio and click the SDK Manager button on the toolbar. After the SDK Manager has fully loaded., close Android Studio.

1

We’re building for Android 4.4.2 so make sure the following packages are checked under the Tools section:

● Android SDK Tools rev 23● Android Platform-tools rev 20● Android SDK Build-tools rev 20● Android SDK Build-tools rev 19.1

Check these under Android L (API 20, L Preview):● SDK Platform Android L Preview● Intel x86 Atom System Image

Check these under the Android 4.4.2(API 19) section:● SDK Platform● Intel x86 Atom System Image● Google APIs (x86 System Image)

And check these under the Extras section:● Android Support Repository● Android Support Library

Click Install. Accept the licenses that appear for each section to enable download.

2

Page 6: Android Studio Setup Guide for Mac - S3 amazonaws com

Create an Android Virtual Device (AVD)

Open Android Studio and click AVD Manager in the toolbar. AVDs allow us to test and run our Android apps.1

Use the following settings for a Nexus5 AVD.:Device: Nexus 5 (4.95, 1080 x 1920; xxhdpi)Target: Google APIs x86 (Google Inc.) - API Level 19(Make sure you select the target with Google APIs in the name.)CPU: Intel Atom (x86)Check the box for Use Host GPUClick OK

2

You should now see the AVD you created in the AVD Manager, where you can start it, delete it, or create another one!

3

Page 7: Android Studio Setup Guide for Mac - S3 amazonaws com

Hooray, you’re DONE!

Time for a robot dance party.