diff options
Diffstat (limited to 'docs/html/sdk/installing')
-rw-r--r-- | docs/html/sdk/installing/adding-packages.jd | 253 | ||||
-rw-r--r-- | docs/html/sdk/installing/bundle.jd | 42 | ||||
-rw-r--r-- | docs/html/sdk/installing/index.jd | 401 | ||||
-rw-r--r-- | docs/html/sdk/installing/installing-adt.jd | 27 | ||||
-rw-r--r-- | docs/html/sdk/installing/studio.jd | 231 |
5 files changed, 662 insertions, 292 deletions
diff --git a/docs/html/sdk/installing/adding-packages.jd b/docs/html/sdk/installing/adding-packages.jd index bba936e..e6c0118 100644 --- a/docs/html/sdk/installing/adding-packages.jd +++ b/docs/html/sdk/installing/adding-packages.jd @@ -1,63 +1,226 @@ -page.title=Adding Platforms and Packages +page.title=Adding SDK Packages @jd:body +<style> +ol.large { + margin-left:0; +} +ol.large > li { + list-style-position: inside; + list-style-type:none; + margin:30px 0 0 0; + padding:30px 20px; + background:#eee; +} +ol.large > li:nth-child(odd) { +} +ol.large > li:before { + display:inline; + left:-40px; + float:left; + width:20px; + font-size:20px; + line-height:20px; +} +ol.large > li > h2 { + font-size:20px; + line-height:20px; + padding:0 0 0 20px; + margin:0 0 20px 0; + display:inline-block; + font-weight:normal; +} +ol.large > li:nth-child(1):before { + content:"1. "; +} +ol.large > li:nth-child(2):before { + content:"2. "; +} +ol.large > li:nth-child(3):before { + content:"3. "; +} +ol.large > li:nth-child(4):before { + content:"4. "; +} +ol.large > li:nth-child(5):before { + content:"5. "; +} +ol.large > li:nth-child(6):before { + content:"6. "; +} +</style> -<p>The Android SDK separates tools, platforms, and other components into packages you can - download using the Android SDK Manager. The original -SDK package you've downloaded includes only the SDK Tools. To develop an Android app, -you also need to download at least one Android platform and the latest SDK Platform-tools.</p> -<ol> -<li>Launch the SDK Manager. -<p>If you've used the Windows installer to install the SDK tools, you should already have the -Android SDK Manager open. Otherwise, you can launch the Android SDK Manager in one of the following -ways:</p> +<p> +By default, the Android SDK does not include everything you need to start developing. +The SDK separates tools, platforms, and other components into packages you can +download as needed using the +<a href="{@docRoot}tools/help/sdk-manager.html">Android SDK Manager</a>. +So before you can start, there are a few packages you should add to your Android SDK.</p> + +<p>To start adding packages, launch the Android SDK Manager in one of the following ways:</p> <ul> - <li>On Windows, double-click the <code>SDK Manager.exe</code> file at the root of the Android -SDK directory.</li> - <li>On Mac or Linux, open a terminal and navigate to the <code>tools/</code> directory in the -Android SDK, then execute <code>android sdk</code>.</li> + <li>In Eclipse or Android Studio, click <strong>SDK Manager</strong> +<img src="{@docRoot}images/tools/sdk-manager-studio.png" +style="vertical-align:bottom;margin:0;height:17px" /> in the toolbar.</li> + <li>If you're not using Eclipse or Android Studio: + <ul> + <li>Windows: Double-click the <code>SDK Manager.exe</code> file at the root of the Android + SDK directory.</li> + <li>Mac/Linux: Open a terminal and navigate to the <code>tools/</code> directory in the + Android SDK, then execute <code>android sdk</code>.</li> + </ul> + </li> </ul> + +<p>When you open the SDK Manager for the first time, several packages will be selected by +default. Leave these selected, but be sure you have everything you need +to get started by following these steps:</p> + + +<ol class="large"> +<li> + <h2 id="GetTools" class="norule">Get the latest SDK tools</h2> + +<img src="/images/sdk_manager_packages.png" alt="" width="350" style="float:right;margin-left:20px" /> + + <p>As a minimum when setting up the Android SDK, + you should download the latest tools and Android platform:</p> + <ol> + <li>Open the Tools directory and select: + <ul> + <li><strong>Android SDK Tools</strong></li> + <li><strong>Android SDK Platform-tools</strong></li> + <li><strong>Android SDK Build-tools</strong> (highest version)</li> + </ul> + </li> + <li>Open the first Android X.X folder (the latest version) and select: + <ul> + <li><strong>SDK Platform</strong></li> + <li>A system image for the emulator, such as <br> + <strong>ARM EABI v7a System Image</strong></li> + </ul> + </li> + </ol> </li> -<li>The SDK Manager shows all the SDK packages available for you to add to your Android SDK. -As a minimum configuration for your SDK, we recommend you install the following: -<ul> - <li>The latest Tools packages (check the <strong>Tools</strong> folder).</li> - <li>The latest version of Android (check the first <strong>Android</strong> folder).</li> - <li>The Android Support Library (open the <strong>Extras</strong> folder and check - <strong>Android Support Library</strong>).</li> -</ul> +<li> + <h2 id="GetSupportLib" class="norule">Get the support library for additional APIs</h2> -<p>Once you've chosen your packages, click <strong>Install</strong>. The Android SDK Manager -installs the selected packages into your Android SDK environment.</li> -</ol> + <div class="sidebox"> + <p>The support library is required for:</p> + <ul> + <li><a href="{@docRoot}wear/index.html">Android Wear</a></li> + <li><a href="{@docRoot}tv/index.html">Android TV</a></li> + <li><a href="{@docRoot}google/play-services/cast.html">Google Cast</a></li> + </ul> -<p>With these packages installed, you're ready to start developing. -To get started, read <a href="{@docRoot}training/basics/firstapp/index.html" ->Building Your First App</a>.</p> + <p>It also provides these popular APIs:</p> + <ul> + <li><a href="{@docRoot}reference/android/support/v4/widget/DrawerLayout.html">Navigation + drawer</a></li> + <li><a href="{@docRoot}reference/android/support/v4/view/ViewPager.html">Swipe views</a></li> + <li><a href="{@docRoot}reference/android/support/v7/app/ActionBar.html">Backward-compatible + action bar</a></li> + </ul> + </div> -<img src="/images/sdk_manager_packages.png" alt="" height="396" /> -<p class="img-caption"><strong>Figure 1.</strong> The Android SDK Manager shows the -SDK packages that are available, already installed, or for which an update is available.</p> + <p>The <a href="{@docRoot}tools/support-library/features.html">Android Support Library</a> + provides an extended set of APIs that are compatible with most versions of Android.</p> + <p>Open the <strong>Extras</strong> directory and select:</p> + <ul> + <li><strong>Android Support Repository</strong></li> + <li><strong>Android Support Library</strong></li> + </ul> + <p> </p> + <p> </p> -<h3>Additional information</h3> +</li> -<ul> - <li>For more information about using the SDK Manager and some of the available packages, -see the <a href="{@docRoot}tools/help/sdk-manager.html">SDK Manager</a> document.</li> - <li>This web site provides all information you need to develop Android apps, including <a -href="{@docRoot}design/index.html">design guidelines</a>, -<a href="{@docRoot}training/index.html">developer training</a>, <a -href="{@docRoot}reference/packages.html">API reference</a>, and information -about how you can <a href="{@docRoot}distribute/index.html">distribute your app</a>. We recommend -you begin by reading <a href="{@docRoot}training/basics/firstapp/index.html" ->Building Your First App</a>.</li> - <li>For additional resources about developing and distributing your app, see the -<a href="{@docRoot}support.html">Developer Support Resources</a>.</li> -</ul> + +<li> + <h2 id="GetGoogle" class="norule">Get Google Play services for even more APIs</h2> + + <div class="sidebox"> + + <p>The Google Play services APIs provide a variety of features and services for your Android + apps, such as:</p> + <ul> + <li><a href="{@docRoot}google/play-services/plus.html">User authentication</a></li> + <li><a href="{@docRoot}google/play-services/maps.html">Google Maps</a></li> + <li><a href="{@docRoot}google/play-services/cast.html">Google Cast</a></li> + <li><a href="{@docRoot}google/play-services/games.html">Games achievements and + leaderboards</a></li> + <li><a href="{@docRoot}google/play-services/index.html">And much more</a></li> + </ul> + </div> + + <p>To develop with Google APIs, you need the Google Play services package:</p> + <p>Open the <strong>Extras</strong> directory and select:</p> + <ul> + <li><strong>Google Repository</strong></li> + <li><strong>Google Play services</strong></li> + </ul> + + <p class="note"><strong>Note:</strong> Google Play services APIs are not available on all + Android-powered devices, but are available on all devices with Google Play Store. To use these + APIs in the Android emulator, you must also install the the <strong>Google APIs</strong> + system image from the latest Android X.X directory in the SDK Manager.</p> +</li> + + +<li> + <h2 id="Install" class="norule">Install the packages</h2> + <p>Once you've selected all the desired packages, continue to install:</p> + <ol> + <li>Click <strong>Install X packages</strong>.</li> + <li>In the next window, double-click each package name on the left + to accept the license agreement for each.</li> + <li>Click <strong>Install</strong>.</li> + </ol> + <p>The download progress is shown at the bottom of the SDK Manager window. + <strong>Do not exit the SDK Manager</strong> or it will cancel the download.</p> +</li> + +<li> + <h2 id="Build" class="norule">Build something!</h2> + +<p>With the above packages now in your Android SDK, you're ready to build apps +for Android. As new tools and other APIs become available, simply launch the SDK Manager + to download the new packages for your SDK.</p> + +<p>Here are a few options for how you should proceed:</p> + +<div class="cols" style="padding:10px 0"> +<div class="col-4"> +<h3>Get started</h3> +<p>If you're new to Android development, learn the basics of Android apps by following +the guide to <strong><a href="{@docRoot}training/basics/firstapp/index.html" +>Building Your First App</a></strong>.</p> + +</div> +<div class="col-4 box"> +<h3>Build for wearables</h3> +<p>If you're ready to start building apps for Android wearables, see the guide to +<strong><a href="{@docRoot}wear/preview/start.html">Building Apps for Android Wear</a></strong>.</p> + +</div> +<div class="col-4 box"> +<h3>Use Google APIs</h3> +<p>To start using Google APIs, such as Maps or +Play Game services, see the guide to +<strong><a href="{@docRoot}google/play-services/setup.html">Setting Up Google Play +Services</a></strong>.</p> + +</div> +</div><!-- end cols --> + + +</li> + +</ol> diff --git a/docs/html/sdk/installing/bundle.jd b/docs/html/sdk/installing/bundle.jd index 1f7da55..22bdd11 100644 --- a/docs/html/sdk/installing/bundle.jd +++ b/docs/html/sdk/installing/bundle.jd @@ -1,45 +1,3 @@ page.title=Setting Up the ADT Bundle @jd:body - - -<p>The ADT Bundle provides everything you need to start developing apps, including -a version of the Eclipse IDE with built-in <b>ADT (Android Developer Tools)</b> to -streamline your Android app development. -If you haven't already, go download the <a href="{@docRoot}sdk/index.html" ->Android ADT Bundle</a>. (If you downloaded the SDK Tools only, for use with an -existing IDE, you should instead read -<a href="{@docRoot}sdk/installing/index.html">Setting Up an Existing IDE</a>.)</p> - -<h3>Install the SDK and Eclipse IDE</h3> -<ol> -<li>Unpack the ZIP file -(named {@code adt-bundle-<os_platform>.zip}) and save it to an appropriate location, -such as a "Development" directory in your home directory.</li> -<li>Open the {@code adt-bundle-<os_platform>/eclipse/} directory and launch -<strong>eclipse</strong>.</li> -</ol> - -<p>That's it! The IDE is already loaded with the Android Developer Tools plugin and -the SDK is ready to go. To start developing, read <a href="{@docRoot}training/basics/firstapp/index.html" ->Building Your First App</a>.</p> - -<p class="caution"><strong>Caution:</strong> Do not move any of the files or directories -from the {@code adt-bundle-<os_platform>} directory. If you move the {@code eclipse} -or {@code sdk} directory, ADT will not be able to locate the SDK and you'll -need to manually update the ADT preferences.</p> - -<h3>Additional information</h3> - -<p>As you continue developing apps, you may need to install additional versions -of Android for the emulator and other packages such as the library for -Google Play In-app Billing. To install more packages, use -the <a href="{@docRoot}tools/help/sdk-manager.html">SDK Manager</a>.</p> - -<p>Everything you need to develop Android apps is on this web site, including <a -href="{@docRoot}design/index.html">design guidelines</a>, -<a href="{@docRoot}training/index.html">developer training</a>, <a -href="{@docRoot}reference/packages.html">API reference</a>, and information -about how you can <a href="{@docRoot}distribute/index.html">distribute your app</a>. -For additional resources about developing and distributing your app, see the -<a href="{@docRoot}support.html">Developer Support Resources</a>.</p>
\ No newline at end of file diff --git a/docs/html/sdk/installing/index.jd b/docs/html/sdk/installing/index.jd index 6b63ba7..3671726 100644 --- a/docs/html/sdk/installing/index.jd +++ b/docs/html/sdk/installing/index.jd @@ -1,19 +1,213 @@ -page.title=Setting Up an Existing IDE +page.title=Installing the Android SDK @jd:body +<style> +.paging-links { + margin:0 0 80px; +} +.paging-links .next-page-link { + right:initial; +} +.procedure-box { + padding:20px 20px 5px; + margin-bottom:1em; + background:#eee; +} +</style> -<p>You should have already downloaded the <a href="{@docRoot}sdk/index.html#ExistingIDE" ->Android SDK Tools</a>. (If you downloaded the ADT Bundle, you should instead read -<a href="{@docRoot}sdk/installing/bundle.html">Setting Up the ADT Bundle</a>.)</p> -<p>The SDK Tools package is not the complete SDK environment. It includes only the core SDK tools, which you can -use to download the rest of the SDK packages (such as the latest system image).</p> +<!-- ################### ADT BUNDLE ####################### --> +<div id="adt" heading="Installing the Eclipse ADT Bundle" style="display:none"> -<div id="win" class="docs" style="display:none"> -<h3>Getting started on Windows</h3> +<p>The Eclipse ADT Bundle provides everything you need to start developing apps, including +the Android SDK tools and a version of the Eclipse IDE with built-in ADT +(Android Developer Tools) to streamline your Android app development.</p> + +<p>If you didn't download the Eclipse ADT bundle, go <a href="{@docRoot}sdk/index.html" +><b>download the Eclipse ADT bundle now</b></a>, or switch to the +<a href="{@docRoot}sdk/installing/index.html?pkg=studio">Android Studio +install</a> or <a href="{@docRoot}sdk/installing/index.html?pkg=tools">stand-alone SDK Tools +install</a> instructions</i>.</p> + +<div class="procedure-box"> +<p><b>To set up the ADT Bundle:</b></p> +<ol> +<li>Unpack the ZIP file +(named {@code adt-bundle-<os_platform>.zip}) and save it to an appropriate location, +such as a "Development" directory in your home directory.</li> +<li>Open the {@code adt-bundle-<os_platform>/eclipse/} directory and launch +<strong>Eclipse</strong>.</li> +</ol> + +<p class="caution"><strong>Caution:</strong> Do not move any of the files or directories +from the {@code adt-bundle-<os_platform>} directory. If you move the {@code eclipse/} +or {@code sdk/} directory, ADT will not be able to locate the SDK and you'll +need to manually update the ADT preferences.</p> +</div> + +<p>Eclipse with ADT is now ready and loaded with the Android developer tools, but there are still +a couple packages you should add to make your Android SDK complete.</p> + +<p class="paging-links"> +<a href="{@docRoot}sdk/installing/adding-packages.html" class="next-page-link"> +Continue: Adding SDK Packages</a></p> + + +</div> +<!-- ################ END ADT BUNDLE ##################### --> + + + + + + +<!-- ################ STUDIO ##################### --> +<div id="studio" heading="Installing Android Studio" style="display:none"> + +<p>Android Studio provides everything you need to start developing apps, including +the Android SDK tools and the Android Studio IDE (powered by IntelliJ) to +streamline your Android app development.</p> + +<p>If you didn't download Android Studio, go <a href="{@docRoot}sdk/installing/studio.html" +><b>download Android Studio now</b></a>, or switch to the +<a href="{@docRoot}sdk/installing/index.html?pkg=adt">Eclipse ADT +install</a> or <a href="{@docRoot}sdk/installing/index.html?pkg=tools">stand-alone SDK Tools +install</a> instructions.</p> + + +<p>Before you set up Android Studio, be sure you have installed +JDK 6 or greater (the JRE alone is not sufficient). To check if you +have JDK installed (and which version), open a terminal and type <code>javac -version</code>. +If the JDK is not available or the version is lower than 6, +<a href="http://www.oracle.com/technetwork/java/javase/downloads/index.html" class="external-link" +>go download JDK</a>.</p> + + +<div class="procedure-box"> + +<p id="instructions-toggle" +style="float:right;font-size:13px"><a href='' onclick='showAll();return false;' +>[ Show instructions for all platforms ]</a></p> + +<div class="win docs" style="display:none"> + +<p><b>To set up Android Studio on Windows:</b></p> + <ol> + <li>Launch the downloaded EXE file, {@code android-studio-bundle-<version>.exe}.</li> + <li>Follow the setup wizard to install Android Studio. + + <p>On some Windows systems, the launcher script does not find where Java is installed. + If you encounter this problem, + you need to set an environment variable indicating the correct location.</p> + <p>Select <strong>Start menu > Computer > System Properties > + Advanced System Properties</strong>. Then open <strong>Advanced tab > Environment + Variables</strong> and add a new system variable <code>JAVA_HOME</code> that points to + your JDK folder, for example <code>C:\Program Files\Java\jdk1.7.0_21</code>.</p> + </p> + </li> + + </ol> + + +<p>The individual tools and +other SDK packages are saved within the Android Studio application directory. +If you need to access the tools directly, use a terminal to navigate into the application and locate +the {@code sdk/} directory. For example:</p> +<p><code>\Users\<user>\AppData\Local\Android\android-studio\sdk\</code></p> + + + +</div><!-- end windows --> + + +<div class="mac docs" style="display:none"> + +<p><b>To set up Android Studio on Mac OSX:</b></p> + <ol> + <li>Open the downloaded DMG file, {@code android-studio-bundle-<version>.dmg}.</li> + <li>Drag and drop Android Studio into the Applications folder. + <p> + Depending on your security settings, when you attempt to open Android Studio, you might + see a warning that says the package is damaged and should be moved to the trash. If this + happens, go to <strong>System Preferences > Security & Privacy</strong> and under + <strong>Allow applications downloaded from</strong>, select <strong>Anywhere</strong>. + Then open Android Studio again.</p> + </li> + </ol> + +<p>The individual tools and +other SDK packages are saved within the Android Studio application directory. +If you need access the tools directly, use a terminal to navigate into the application and locate +the {@code sdk/} directory. For example:</p> +<p><code>/Applications/Android\ Studio.app/sdk/</code></p> + + +</div><!-- end mac --> + + +<div class="linux docs" style="display:none"> + +<p><b>To set up Android Studio on Linux:</b></p> + + <ol> + <li>Unpack the downloaded Tar file, {@code android-studio-bundle-<version>.tgz}, into an appropriate + location for your applications. + <li>To launch Android Studio, navigate to the {@code android-studio/bin/} directory + in a terminal and execute {@code studio.sh}. + <p>You may want to add {@code android-studio/bin/} to your PATH environmental + variable so that you can start Android Studio from any directory.</p> + </li> + </ol> + +</div><!-- end linux --> +</div><!-- end procedure box --> + +<p>Android Studio is now ready and loaded with the Android developer tools, but there are still a +couple packages you should add to make your Android SDK complete.</p> + +<p class="paging-links"> +<a href="{@docRoot}sdk/installing/adding-packages.html" class="next-page-link"> +Continue: Adding SDK Packages</a></p> + + +</div> +<!-- ################ END STUDIO ##################### --> + + + + + + + + + +<!-- ################ JUST SDK TOOLS ##################### --> +<div id="tools" heading="Installing the Stand-alone SDK Tools" style="display:none"> + + +<p>The stand-alone SDK Tools package does not include a complete Android development environment. +It includes only the core SDK tools, which you can access from a command line or with a plugin +for your favorite IDE (if available).</p> + +<p>If you didn't download the SDK tools, go <a href="{@docRoot}sdk/index.html" +><b>download the SDK now</b></a>, +or switch to the <a href="{@docRoot}sdk/installing/index.html?pkg=adt">Eclipse ADT +install</a> or <a href="{@docRoot}sdk/installing/index.html?pkg=studio">Android Studio +install</a> instructions.</p> + + +<div class="procedure-box"> +<p id="instructions-toggle" +style="float:right;font-size:13px"><a href='' onclick='showAll();return false;' +>[ Show instructions for all platforms ]</a></p> + +<div class="win docs" style="display:none"> + +<p><b>To get started on Windows:</b></p> + <p>Your download package is an executable file that starts an installer. The installer checks your machine for required tools, such as the proper Java SE Development Kit (JDK) and installs it if necessary. The installer then saves the Android SDK Tools into a default location (or you can specify the location).</p> @@ -21,15 +215,9 @@ use to download the rest of the SDK packages (such as the latest system image).< <ol> <li>Double-click the executable ({@code .exe} file) to start the install.</li> <li>Make a note of the name and location in which it saves the SDK on your system—you will need to -refer to the SDK directory later, when setting up the ADT plugin and when using +refer to the SDK directory later when using the SDK tools from the command line.</li> -<li>Once the installation completes, the installer offers to start the Android SDK Manager. -If you'll be using Eclipse, <strong>do not</strong> start the Android SDK Manager, -and instead move on to <a href="{@docRoot}sdk/installing/installing-adt.html" ->Installing the Eclipse Plugin</a>. -<p>If you're using a different IDE, -start the SDK Manager and read <a href="{@docRoot}sdk/installing/adding-packages.html" ->Adding Platforms and Packages</a>.</p> +<li>Once the installation completes, the installer starts the Android SDK Manager. </li> </ol> @@ -37,51 +225,37 @@ start the SDK Manager and read <a href="{@docRoot}sdk/installing/adding-packages -<div id="mac" class="docs" style="display:none"> +<div class="mac docs" style="display:none"> -<h3>Getting started on Mac</h3> +<p><b>To get started on Mac OSX:</b></p> -<ol> -<li>Unpack the ZIP file you've downloaded. By default, it's unpacked +<p>Unpack the ZIP file you've downloaded. By default, it's unpacked into a directory named <code>android-sdk-mac_x86</code>. Move it to an appropriate location on your machine, -such as a "Development" directory in your home directory. +such as a "Development" directory in your home directory.</p> <p>Make a note of the name and location of the SDK directory on your system—you will need to -refer to the SDK directory later, when setting up the ADT plugin and when using +refer to the SDK directory later when using the SDK tools from the command line.</p> -</li> -<li>If you're using Eclipse, move on to <a href="{@docRoot}sdk/installing/installing-adt.html" ->Installing the Eclipse Plugin</a>. Otherwise, if you're using a different IDE, -read <a href="{@docRoot}sdk/installing/adding-packages.html" ->Adding Platforms and Packages</a>.</li> -</ol> </div> -<div id="linux" class="docs" style="display:none"> +<div class="linux docs" style="display:none"> -<h3>Getting started on Linux</h3> +<p><b>To get started on Linux:</b></p> -<ol> -<li>Unpack the {@code .tgz} file you've downloaded. By default, the SDK files are unpacked +<p>Unpack the {@code .tgz} file you've downloaded. By default, the SDK files are unpacked into a directory named <code>android-sdk-linux_x86</code>. Move it to an appropriate location on your machine, -such as a "Development" directory in your home directory. +such as a "Development" directory in your home directory.</p> <p>Make a note of the name and location of the SDK directory on your system—you will need to -refer to the SDK directory later, when setting up the ADT plugin and when using +refer to the SDK directory later when using the SDK tools from the command line.</p> -</li> -<li>If you're using Eclipse, move on to <a href="{@docRoot}sdk/installing/installing-adt.html" ->Installing the Eclipse Plugin</a>. Otherwise, if you're using a different IDE, -read <a href="{@docRoot}sdk/installing/adding-packages.html" ->Adding Platforms and Packages</a>.</li> -</ol> -<h5 id="Troubleshooting"><a href='' class="expandable" +<h5 id="Troubleshooting" style="margin-bottom:15px"><a href='' class="expandable" onclick="toggleExpandable(this,'#ubuntu-trouble');return false;" >Troubleshooting Ubuntu</a></h5> @@ -122,38 +296,129 @@ sudo apt-get install libncurses5:i386 libstdc++6:i386 zlib1g:i386</pre> </div><!-- end ubuntu trouble --> +</div><!-- end linux --> +</div><!-- end procedure box --> + + +<p>The Android SDK tools are now ready to begin developing apps, but there are still a +couple packages you should add to make your Android SDK complete.</p> + +<p class="paging-links"> +<a href="{@docRoot}sdk/installing/adding-packages.html" class="next-page-link"> +Continue: Adding SDK Packages</a></p> + + </div> +<!-- ################ END JUST TOOLS ##################### --> + + + + + +<!-- ################ DEFAULT ##################### --> +<style> +h3.large-link { + display:inline-block; + width:100%; + text-align:center; + border:1px solid #258aaf; + padding:10px 0; + color:inherit; +} +</style> + +<div id="default" style="display:none"> + +<p>If you haven't already done so, <b><a href="{@docRoot}sdk/index.html">click here to download +the Android SDK</a></b>. </p> + +<p>Otherwise, select which SDK package you want to install:</p> + +<div class="cols" style="margin-bottom:60px"> +<div class="col-4"> +<a href="{@docRoot}sdk/installing/index.html?pkg=adt"> +<h3 class="large-link">Eclipse ADT</h3> +</a> +</div> + +<div class="col-4"> +<a href="{@docRoot}sdk/installing/index.html?pkg=studio"> +<h3 class="large-link">Android Studio</h3></a> +</div> + +<div class="col-4"> +<a href="{@docRoot}sdk/installing/index.html?pkg=tools"> +<h3 class="large-link">Stand-alone SDK Tools</h3></a> +</div> +</div> + + +</div> +<!-- ################ END DEFAULT ##################### --> + + + + -<p style="margin-top:2em;"><a href='' onclick='showAll();return false;'>Information for other platforms</a></p> <script> - var $osDocs; - if (navigator.appVersion.indexOf("Win")!=-1) { - $osDocs = $('#win'); - } else if (navigator.appVersion.indexOf("Mac")!=-1) { - $osDocs = $('#mac'); - } else if (navigator.appVersion.indexOf("Linux")!=-1) { - $osDocs = $('#linux'); - } - if ($osDocs.length) { - // reveal only the docs for this OS - $osDocs.show(); - } else { - // not running a compatible OS, so just show all the docs - $('.docs').show(); +// Show proper instructions based on downloaded SDK package +var package = getUrlParam("pkg"); +if (package == "tools") { + // Show the SDK Tools (other IDE) instructions + $("h1").text($("#tools").attr('heading')); + $("#tools").show(); +} else if (package == "adt") { + // Show the ADT instructions + $("h1").text($("#adt").attr('heading')); + $("#adt").show(); +} else if (package == "studio") { + // Show the Android Studio instructions + $("h1").text($("#studio").attr('heading')); + $("#studio").show(); +} else { + // Show the default page content so user can select their setup + $("#default").show(); +} + +// Show the proper instructions based on machine OS +var $osDocs; +if (navigator.appVersion.indexOf("Win")!=-1) { + $osDocs = $('.win'); +} else if (navigator.appVersion.indexOf("Mac")!=-1) { + $osDocs = $('.mac'); +} else if (navigator.appVersion.indexOf("Linux")!=-1) { + $osDocs = $('.linux'); +} + +if ($osDocs.length) { + // reveal only the docs for this OS + $osDocs.show(); +} else { + // not running a compatible OS, so just show all the docs + $('.docs').show(); +} + + +/* Shows all the machine OS instructions */ +function showAll() { + $('.docs').show(); + $("#instructions-toggle").hide(); +} + +/* Returns the value for the given URL parameter */ +function getUrlParam(param) { + var url = window.location.search.substring(1); + var variables = url.split('&'); + for (var i = 0; i < variables.length; i++) { + var paramName = variables[i].split('='); + if (escape(paramName[0]) == param) { + return escape(paramName[1]); + } } +} + + - function showAll() { - $('.docs').each(function() { - if (!$(this).is(':visible')) { - console.log('show') - $(this).show(); - } else { - console.log('hide') - $(this).hide(); - $osDocs.show(); - } - }); - } </script> diff --git a/docs/html/sdk/installing/installing-adt.jd b/docs/html/sdk/installing/installing-adt.jd index 7bf366c..1e87cd8 100644 --- a/docs/html/sdk/installing/installing-adt.jd +++ b/docs/html/sdk/installing/installing-adt.jd @@ -15,19 +15,28 @@ of Eclipse to let you quickly set up new Android projects, build an app UI, debug your app, and export signed (or unsigned) app packages (APKs) for distribution. </p> -<p>If you need to install Eclipse, you can download it from <a href= -"http://www.eclipse.org/downloads/">eclipse.org/downloads/</a>.</p> - - -<p class="note"><strong>Note:</strong> If you prefer to work in a different IDE, you do not need to -install Eclipse or ADT. Instead, you can directly use the SDK tools to build and -debug your application.</p> - +<p class="note"><strong>Note:</strong> You should install the ADT plugin +only if you already have an Eclipse installation that you want to continue using. If you do not +have Eclipse installed, you should instead <b><a href="{@docRoot}sdk/index.html">install +the complete Android SDK</a></b>, which includes the latest IDE for Android developers.</p> + +<p>Your existing Eclipse installation must meet these requirements:</p> + <ul> + <li><a href="http://eclipse.org/mobile/">Eclipse</a> 3.7.2 (Indigo) or greater +<p class="note"><strong>Note:</strong> Eclipse 3.6 (Helios) is no longer +supported with the latest version of ADT.</p></li> + <li>Eclipse <a href="http://www.eclipse.org/jdt">JDT</a> plugin (included +in most Eclipse IDE packages) </li> + <li><a href="http://www.oracle.com/technetwork/java/javase/downloads/index.html">JDK 6</a> + (JRE alone is not sufficient)</li>oid Development Tools plugin</a> +(recommended)</li> + <li><strong>Not</strong> compatible with GNU Compiler for Java (gcj)</li> + </ul> <h2 id="Download">Download the ADT Plugin</h2> - +<p>To add the ADT plugin to Eclipse:</p> <ol> <li>Start Eclipse, then select <strong>Help</strong> > <strong>Install New Software</strong>.</li> diff --git a/docs/html/sdk/installing/studio.jd b/docs/html/sdk/installing/studio.jd index 2ad5808..8ac6163 100644 --- a/docs/html/sdk/installing/studio.jd +++ b/docs/html/sdk/installing/studio.jd @@ -1,4 +1,4 @@ -page.title=Getting Started with Android Studio +page.title=Android Studio page.tags="studio" @jd:body @@ -7,7 +7,7 @@ page.tags="studio" <div style="position:relative;min-height:660px;"> -<h3 style="color:#f80">EARLY ACCESS PREVIEW</h3> +<h3 style="color:#FF4444;margin:-30px 0 20px">BETA</h3> <div id="tos" style="position:absolute;display:none;width:inherit;"> <div class="col-13" style="margin:0;"> </div><!-- provides top margin for content --> @@ -183,23 +183,21 @@ This is the Android Software Development Kit License Agreement - - <div id="main"> -<div class="figure" style="width:400px;margin-top:-20px"> +<div class="figure" style="width:400px;margin-top:-75px"> <img src="{@docRoot}images/tools/android-studio.png" height="330" width="400" style="margin-bottom:20px" /> <a class="big button subtitle" id="download-ide-button" -href="" style="display:none;width:265px;margin:0 auto;display:block;font-size:18px" ></a> -<div style="width:290px;padding:10px 40px 0 60px;font-size:12px;line-height:16px"> +href="" style="display:none;width:368px;margin:0 auto;display:block;font-size:18px" ></a> +<div style="margin:20px 0 0 0"> <p style="margin-bottom:8px">This download includes:</p> -<ul> -<li>Android Studio <b>early access preview</b></li> -<li>All the Android SDK Tools to design, test, debug, and profile your app</li> -<li>The latest Android platform to compile your app</li> -<li>The latest Android system image to run your app in the emulator</li> +<ul style="margin-bottom:20px"> +<li>Android Studio Beta</li> +<li>All the Android SDK Tools to design, test, and debug your app</li> +<li>A version of the Android platform to compile your app</li> +<li>A version of the Android system image to run your app in the emulator</li> </ul> </div> @@ -208,36 +206,34 @@ href="" style="display:none;width:265px;margin:0 auto;display:block;font-size:18 <p>Android Studio is a new Android development environment based on IntelliJ -IDEA. Similar to Eclipse with the -ADT Plugin, Android Studio provides integrated Android developer tools -for development and debugging. On top of the +IDEA. It provides new features and improvements over Eclipse ADT +and will be the official Android IDE once it's ready. On top of the capabilities you expect from IntelliJ, Android Studio offers:</p> <ul> - <li>Gradle-based build support.</li> - <li>Android-specific refactoring and quick fixes.</li> - <li>Lint tools to catch performance, usability, version compatibility and other problems.</li> - <li>ProGuard and app-signing capabilities. </li> - <li>Template-based wizards to create common Android designs and components.</li> - <li>A rich layout editor that allows you to drag-and-drop UI components, preview layouts on - multiple screen configurations, and much more.</li> + <li>Flexible Gradle-based build system.</li> + <li>Build variants and multiple APK generation.</li> + <li>Expanded template support for Google Services and various device types.</li> + <li>Rich layout editor with support for theme editing.</li> + <li>Lint tools to catch performance, usability, version compatibility, and other problems.</li> + <li>ProGuard and app-signing capabilities.</li> <li>Built-in support for <a href="http://android-developers.blogspot.com/2013/06/adding-backend-to-your-app-in-android.html" class="external-link">Google Cloud Platform</a>, making it easy to integrate Google Cloud - Messaging and App Engine as server-side components. + Messaging and App Engine. </ul> -<p class="caution"><strong>Caution:</strong> Android Studio is currently available as -an <strong>early access preview</strong>. Several features -are either incomplete or not yet implemented and you may encounter bugs. If you are not +<p class="caution"><strong>Caution:</strong> Android Studio is currently in +<strong>beta</strong>. Some features +are not yet implemented and you may encounter bugs. If you are not comfortable using an unfinished product, you may want to instead -download (or continue to use) the -<a href="{@docRoot}sdk/index.html">ADT Bundle</a> (Eclipse with the ADT Plugin).</p> +download (or continue to use) +<a href="{@docRoot}sdk/index.html">Eclipse with ADT</a>.</p> -<h4 style="clear:right;text-align:right;margin-right:50px"><a href='' class="expandable" +<h4 style="margin-top: 20px;"><a href='' class="expandable" onclick="toggleExpandable(this,'.pax');return false;" - >DOWNLOAD FOR OTHER PLATFORMS</a></h4> + >VIEW ALL DOWNLOADS AND SIZES</a></h4> <div class="pax col-13 online" style="display:none;margin:0;"> @@ -290,6 +286,73 @@ download (or continue to use) the +<h2 style="margin-bottom: 0px;">Android Studio vs. Eclipse ADT Comparison</h2> + +<p> +The following table lists some key differences between Android Studio Beta and +<a href="{@docRoot}sdk/index.html">Eclipse with ADT</a>. +</p> + +<style> +td.yes { + color: #669900; +} +td.no { + color: #CC0000; +} +</style> + +<table> + <tbody><tr> + <th>Feature</th> + <th>Android Studio</th> + <th>ADT</th> + </tr> + <tr> + <td>Build system</td> + <td><a href="http://www.gradle.org/" class="external-link">Gradle</a></td> + <td><a href="http://ant.apache.org/" class="external-link">Ant</a></td> + </tr> + <tr> + + <td>Maven-based build dependencies</td> + <td class="yes">Yes</td> + <td class="no">No</td> + </tr> + + <td>Build variants and multiple-APK generation (great for Android Wear)</td> + <td class="yes">Yes</td> + <td class="no">No</td> + </tr> + + <tr> + <td>Advanced Android code completion and refactoring</td> + <td class="yes">Yes</td> + <td class="no">No</td> + </tr> + <tr> + <td>Graphical layout editor</td> + <td class="yes">Yes</td> + <td class="yes">Yes</td> + </tr> + <tr> + </tr> + + <tr> + <td>APK signing and keystore management</td> + <td class="yes">Yes</td> + <td class="yes">Yes</td> + </tr> + + <tr> + <td>NDK support</td> + <td class="no">Coming soon</td> + <td class="yes">Yes</td> + </tr> + </tbody></table> + + + <h2 id="Updating">Updating from older versions</h2> <p>If you already have Android Studio installed, in most cases, you can upgrade to the latest @@ -298,7 +361,7 @@ version by installing a patch. From within Android Studio, select Check for updates</strong>) to see whether an update is available.</p> <p>If an update is not available, -follow the <a href="#Installing">installation instructions</a> below and replace your existing +click the button above to download and replace your existing installation.</p> <div class="caution"> @@ -311,98 +374,6 @@ If you fail to copy these packages, then you can instead download them again thr the Android SDK Manager.</p> </div> - -<h2 id="Installing">Installing Android Studio</h2> -<p>Android Studio requires JDK 6 or greater (JRE alone is not sufficient). To check if you -have JDK installed (and which version), open a terminal and type <code>javac -version</code>. -If JDK is not available or the version is lower than 6, -<a href="http://www.oracle.com/technetwork/java/javase/downloads/index.html">download -JDK from here</a>.</p> -<p>To install Android Studio:</p> -<ol> -<li>Download the <strong>Android Studio</strong> package from above.</li> -<li>Install Android Studio and the SDK tools: - <p><b>Windows:</b></p> - <ol> - <li>Launch the downloaded EXE file, {@code android-studio-bundle-<version>.exe}.</li> - <li>Follow the setup wizard to install Android Studio. - - <div class="caution"><p><strong>Known issue:</strong> - On some Windows systems, the launcher script does not find where Java is installed. - If you encounter this problem, - you need to set an environment variable indicating the correct location.</p> - <p>Select <strong>Start menu > Computer > System Properties > - Advanced System Properties</strong>. Then open <strong>Advanced tab > Environment - Variables</strong> and add a new system variable <code>JAVA_HOME</code> that points to - your JDK folder, for example <code>C:\Program Files\Java\jdk1.7.0_21</code>.</p> - </div> - </li> - - </ol> - <p><b>Mac OS X:</b></p> - <ol> - <li>Open the downloaded DMG file, {@code android-studio-bundle-<version>.dmg}.</li> - <li>Drag and drop Android Studio into the Applications folder. - - <div class="caution"><p><strong>Known issue:</strong> - Depending on your security settings, when you attempt to open Android Studio, you might - see a warning that says the package is damaged and should be moved to the trash. If this - happens, go to <strong>System Preferences > Security & Privacy</strong> and under - <strong>Allow applications downloaded from</strong>, select <strong>Anywhere</strong>. - Then open Android Studio again.</p> - </div> - </li> - - </ol> - <p><b>Linux:</b></p> - <ol> - <li>Unpack the downloaded Tar file, {@code android-studio-bundle-<version>.tgz}, into an appropriate - location for your applications. - <li>To launch Android Studio, navigate to the {@code android-studio/bin/} directory - in a terminal and execute {@code studio.sh}. - <p>You may want to add {@code android-studio/bin/} to your PATH environmental - variable so that you can start Android Studio from any directory.</p> - </li> - </ol> -</li> -</ol> - -<p>That's it! You're ready to start developing apps with Android Studio.</p> - -<div class="note"> -<p><strong>Note:</strong> On Windows and Mac, the individual tools and -other SDK packages are saved within the Android Studio application directory. -To access the tools directly, use a terminal to navigate into the application and locate -the {@code sdk/} directory. For example:</p> -<p>Windows: <code>\Users\<user>\AppData\Local\Android\android-studio\sdk\</code></p> -<p>Mac: <code>/Applications/Android\ Studio.app/sdk/</code></p> -</div> - -<p>For a list of some known issues, see <a -href="http://tools.android.com/knownissues">tools.android.com/knownissues</a>.</p> - - -<h2 id="Start">Starting a Project</h2> - -<p>When you launch Android Studio for the first time, you'll see a Welcome -screen that offers several ways to get started:</p> - -<ul> - <li>To start building a new app, click <strong>New Project</strong>. - <p>This starts the New Project wizard, which helps you set up a project using an app template. - </li> - <li>To import an existing Android app project, click <strong>Import Project</strong>. - <p class="note"><strong>Note:</strong> If you previously developed your Android project - with Eclipse, you should first use the new export feature in the ADT plugin to prepare - your project with the new Gradle build system. For more information, read - <a href="{@docRoot}sdk/installing/migrate.html">Migrating from Eclipse</a>.</p> - </li> -</ul> - -<p>For additional help using Android Studio, read <a -href="{@docRoot}sdk/installing/studio-tips.html">Tips and Tricks</a>.</p> - - <p>As you continue developing apps, you may need to install additional versions of Android for the emulator and other packages such as the <a href="{@docRoot}tools/support-library/index.html">Android Support Library</a>. @@ -599,8 +570,8 @@ for possible resolutions to known issues: <a href="http://tools.android.com/know if (os) { /* set up primary ACE download button */ $('#download-ide-button').show(); - $('#download-ide-button').append("Download Android Studio <span class='small'>v0.5.2</span>" - + "<br/> <span class='small'>for " + os + "</span>"); + $('#download-ide-button').append("Download Android Studio Beta <span class='small'>v0.5.2</span>" + + "<br/> <span class='small'>with the Android SDK for " + os + "</span>"); $('#download-ide-button').click(function() {return onDownload(this,true);}).attr('href', bundlename); } else { @@ -642,9 +613,13 @@ for possible resolutions to known issues: <a href="http://tools.android.com/know function onDownloadForRealz(link) { if ($("input#agree").is(':checked')) { - $("#tos").hide(); - $("#main").show(); - location.hash = "Updating"; + $("h1").text('Now redirecting to the install instructions...'); + $("#tos").slideUp(); + $("#jd-content .jd-descr").fadeOut('slow', function() { + setTimeout(function() { + window.location = "/sdk/installing/index.html?pkg=studio"; + }, 1000); + }); _gaq.push(['_trackEvent', 'SDK', 'Android Studio', $("#downloadForRealz").html()]); return true; } else { |