Mac under eclipse+atd+androidsdk+ Project import

Source: Internet
Author: User

To install the eclipse+atd+android SDK:

First of all, download the android SDK here , this is integrated, all the tools are readily available, eliminating the hassle of downloading a bunch of things. The details include the following:

    • Eclipse + ADT Plugin
    • Android SDK Tools
    • Android Platform-tools
    • The latest Android platform
    • The latest Android system image for the emulator

Once downloaded, unzip the package adt-bundle-mac-x86_64-20140702.zip, then place the unpacked package anywhere you want, and change the name of the folder to Android

Go to the Eclipse folder and you'll see the Eclipse software with the circular icon. Because it's not sold in the Apple Store, right-click Open and Confirm open to open the software.

At this point because you have not downloaded a series of Android API packages, so open the terminal, execute the following command

$CD Android/sdk/tools

$./android SDK

And then you jump out of a window

And then choose to install just fine.

As for the solution that is not a store software that cannot be opened directly, please see here .

Then: Install ADT in Eclipse:

Eclipse 3.4 (Ganymede)

    1. Start Eclipse, then select Help > software Updates.... In the dialog box that appears, click the Available software tab.
    2. Click Add Site
    3. In the Add Site dialog box, enter the following URL in the Location field:http://dl-ssl.google.com/android/eclipse. Click OK.
    4. Back to the Available software interface, click Expand http://dl-ssl.google.com/android/eclipse, you can see the list of plugins included in the URL, which has Developer Tools. Select the check box next to Developer Tools and click Install.
    5. In the installation window that appears, the selected Android DDMS and Android development Tools should appear. Click Next.
    6. Read and accept the license agreement, and then click Finish.
    7. Restart Eclipse.

Eclipse 3.5 (Galileo)

    1. Start Eclipse, then select Help > Install New software.
    2. In the Available Software dialog box, click Add....
    3. In the ADD Site dialog box, in the Name field, enter the name of the remote site (for example, "Android Plugin").
    4. In the Location field, enter the following URL:https://dl-ssl.google.com/android/eclipse/Note: If you encounter problems accessing the plugin, you can change the HTTPS in the URL to HTTP (using HTTPS is a bit more secure). Click OK.
    5. Back to the Available software interface, you should see the Developer Tools option in the list. Select the check box next to Developer tools to select both Android DDMS and Android development tools. Click Next.
    6. In the final Install Details dialog box, features such as Android DDMS and Android development Tools are listed. Click Next to read and accept the license agreement, install all dependent components at the same time, and then click Finish.
    7. Restart Eclipse.

Android projects that were written before the Ecplise workspace import will have errors, most of which are incompatible with the SDK version, with the following error message:
Error:unable to resolve target ANDROID-17

Workaround: Modify the contents of the Project.Properties file in the project directory target=android-5 numbers to the Android SDK version installed in your machine.

Report:
When you use a later version of the SDK and then import a previous version of project, you experience some compatibility issues.
(1) Unable to resolve target android-5
Because the version of SDK,API that is now used in this machine is 7, and the imported project uses 2.0 developed, its API version is 5.2.1.
It would be nice to change the target=android-5 in Project.Properties to target=android-7.
Note, however, to synchronize the androidmanifest.xml in the <uses-sdk android:minsdkversion= "5"/> also to change, otherwise the compiler will warn you that the version used is too low.
(2) After completion, a new error occurred in the compilation: Conversion to Dalvik format failed with error 1
This is related to the loaded SDK, by right-selecting the project build path--Configure build path ...--the library found imported jars in addition to an Android 2.1- Update1 There is also a folder under the same path item, remove it, clean and then compile it is no problem.

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.