0

i tried to installed Android Compatibility to platform 2.2 by clicking right click on my project , android tools , add support library then i got these messages

[2012-12-08 06:13:12 - SDK Manager] Fetching https://dl-ssl.google.com/android/repository/addons_list-1.xml
[2012-12-08 06:13:18 - SDK Manager] Validate XML
[2012-12-08 06:13:18 - SDK Manager] Parse XML
[2012-12-08 06:13:18 - SDK Manager] Fetched Add-ons List successfully
[2012-12-08 06:13:18 - SDK Manager] Fetching URL: https://dl-ssl.google.com/android/repository/repository-6.xml
[2012-12-08 06:13:21 - SDK Manager] Validate XML: https://dl-ssl.google.com/android/repository/repository-6.xml
[2012-12-08 06:13:21 - SDK Manager] Parse XML:    https://dl-ssl.google.com/android/repository/repository-6.xml
[2012-12-08 06:13:21 - SDK Manager]     Found Android SDK Platform-tools, revision 12
[2012-12-08 06:13:21 - SDK Manager]     Found Android SDK Tools, revision 20
[2012-12-08 06:13:21 - SDK Manager] Fetching URL: https://dl-ssl.google.com/android/repository/addon.xml
[2012-12-08 06:13:26 - SDK Manager] Validate XML: https://dl-ssl.google.com/android/repository/addon.xml
[2012-12-08 06:13:26 - SDK Manager] Fetching URL: http://software.intel.com/sites/landingpage/android/addon.xml
[2012-12-08 06:13:28 - SDK Manager] Validate XML: http://software.intel.com/sites/landingpage/android/addon.xml
[2012-12-08 06:13:28 - SDK Manager] Done loading packages.

then i tried to make new Gridlayout on my XML layout but eclipse eclipse doesn't recognize this layout.

  1. has the gridlayout installed?
  2. if yes how could i use it
  3. if i could use it, when i will install the apk on my phone(2.2) have i installed the library on my phone too? of it is moved with apk?

Edit

this is what i got when i open the SDK manager , i am from Syria so is that because Google forbidden its products to syrian? enter image description here

William Kinaan
  • 28,059
  • 20
  • 85
  • 118

2 Answers2

1

enter image description hereGridLayout has been backported to be compatible with API level 7 and up. It's (sort of) part of the support library. After you've downloaded the support library, you'll find an Android library project in your local sdk folder located at:

<sdk_folder>\extras\android\compatibility\v7\gridlayout

Set it up as dependency of the project you're working on. After that, you'll need to make sure you point any references throughout your project to this one, and not the level 15 version, in order to support pre-ICS devices. Usage should be similar, if not identical.

Ali Imran
  • 8,927
  • 3
  • 39
  • 50
  • You can simply add this project as a new library project and add reference to your project for this. – Ali Imran Dec 08 '12 at 14:42
  • thanks for your answer, but how can i installed the library , here is the question – William Kinaan Dec 08 '12 at 14:46
  • i tried from my sdk manager, and on the folder extract i have just seen `google usb driver` – William Kinaan Dec 08 '12 at 14:47
  • see the attached picture for installed packages. and compare it with yours. In there see the android `compatibility` status. – Ali Imran Dec 08 '12 at 14:51
  • see my edited question, i added a picture of what i got when opening the SDK manager, BTY i am from Syria so maybe Google has forbidden its product to syrian? – William Kinaan Dec 08 '12 at 14:59
  • Yes you have no installed packages and this is the problem. And i don't know the policy of Goolgle about Syria :) and i am from Pakistan so no these kind of issues here :P – Ali Imran Dec 08 '12 at 15:08
1

From what it looks like to me is that you didn't get prompted to install the compatibility library. I just did a test run within Eclipse and installed the compatibility library and I got an interactive dialog stating that it found the Android Support Library and had me go through an installation process. This is the output on the console as I downloaded the support library.

[2012-12-08 06:25:13 - SDK Manager] Done loading packages.
[2012-12-08 06:25:18 - SDK Manager] Preparing to install archives
[2012-12-08 06:25:18 - SDK Manager] Downloading Android Support Library, revision 11
[2012-12-08 06:25:22 - SDK Manager] Installing Android Support Library, revision 11
[2012-12-08 06:25:26 - SDK Manager]   Installed Android Support Library, revision 11
[2012-12-08 06:25:26 - SDK Manager] Done. 1 package installed

Perhaps one thing you can try is using the SDK Manager install the Android Support Library under the Extras folder, then after you install it, you would go to Project -> Properties -> Java Build Path. Click on Libraries, and click "Add External JARs". From there you will be asked a JAR file to include and the Support library will be under your SDK install Path/Extras/Android/Support/v##, where the hash tags indicate the version of the Android Support library you have installed. in there there will be an android-support-v##.jar file and that is what you would import into the project.

Hopefully that is helpful.

dmason82
  • 399
  • 4
  • 5
  • i am from Syrian and all google products is forbidden to us so i am trying to installed it using proxy. u helped my with your answer, thanks, +1 for u – William Kinaan Dec 08 '12 at 14:41
  • and when i opened my sdk manager i find under extracts folder just `google usb driver`, i didn't find support – William Kinaan Dec 08 '12 at 14:43