Hello guys,
I just installed the mobile development environment on my Linux laptop. Everything seems to be working properly for new projects, but trying to run the Kitchen Sink app on the Android emulator, always gives me a "failed installing" error. I have tried creating a new project and copying over the Resources folder, but didn't work.
Any comments or ideas?
R. Alcocer
22 Answers
Here is all that I had to do to get things working consistently :
Delete all AVD's
Insure that you have the following Installed Packages (others may be ok, but I paired it down to only these)
- Android SDK Tools, revision 10
- Android SDK Platform-tools, revision 3
- SDK Platform Android 2.2, API 8, revision 2
- SDK Platform Android 2.1-update1, API 7, revision 2
- SDK Platform Android 1.6, API 4, revision 3
- Google APIs by Google Inc., Android API 8, revision 2
- Google APIs by Google Inc., Android API 7, revision 1
- Google APIs by Google Inc., Android API 4, revision 2
- Google Market Licensing package, revision 1
Now, from Titanium Developer, under "Run Emulator > Android" click "Launch"
This is very likely fail, but it will create an AVD baseline for you to modify
Go back the the AVD Manager, refresh the list of Virutal Devices and you should now see something like: "titanium_1_HVG...."
Edit the AVD, make sure that the Target is "Google APIs (Google Inc.) - API Level 8
- Note, I used WQVGA400 but I think others will work ... the key was to use the Google APIs not the Android 2.2 target.
Now, return to the Titanium Developer and you should be able to launch and see it run.
If you see [INSTALL_FAILED_MISSING_SHARED_LIBRARY] in the log it means you're not using the right Emulator. You must use a Google APIs emulator image. Those are designated as "Api X.X" on the Android test and launch screen.
It needs to run on SDK with "API x.x" (Select before you click the launch button).
Ex:
APIs 1.6,
APIs 2.2,
APIs 2.3,
It's working!
I experienced this issue after moving the android SDK after installing the Android SDK and Appcelerator at an earlier date. For those in this situation....when re-installing the android sdk,
__don't forget to re-install the "Third Party Add-Ons" > Google API SDKs __ (Located under the Available Packages > Third Party Add-Ons > Google Inc add-ons
In Appcelerator VERIFY you have listings for 1.6 and APIs 1.6, 2.1 and APIs 2.1
both I forgot about this during the re-install, so the Google API SDK files were not available, and never selectable.
1/7/2011 - The configuration which worked for me (Titanium v 1.5.1) was APIs 1.6 AND Screen == WVGA854
I tried all the advice here and nothing works on Mac OSX 10.6.6 with Titanium 1.2.2
[ERROR] Failed installing com.appcelerator.titanium: pkg: /data/local/tmp/app.apk
No matter which API I choose, no matter if I delete all the emulators and choose API Level 8 Manually by editing the emulator I still get the same error.
The iPhone emulator compiles and runs "appcelerator-KitchenSink-c17b77f" just fine!
Ok, after much deliberation following the instructions from above this has now worked. The only thing to bear in mind is that I tried to set the API using "Run Configurations" within Titanium and that did not work. However, when set the API to a Google API (as opposed to Android API) from with AVD Manager (launched using executable android) then this error stopped appearing.
Thank you all for the help.
I had the same error and got it running by choosing the Android SDK "APIs 2.2"
I had to download that SDK using the Android download manager inside the Android plugin for eclipse
You should also make sure that you have python2.5 installed
Ubuntu lucid lynx doesn't officially support python2.5 so you have to install the unofficial python2.5 package from here https://launchpad.net/~fkrull/+archive/deadsnakes
Still no success with the 1.5 or 2.1 emulators.
This message now appears while building:
[ERROR] /opt/android-sdk/tools/apkbuilder /home/ralcocer/Desktop/Tecnologia Libre/My Titanium Apps/Mobile/KitchenSink/build/android/bin/classes.dex does not exists! [ERROR] /opt/android-sdk/tools/zipalign Unable to open '/home/ralcocer/Desktop/Tecnologia Libre/My Titanium Apps/Mobile/KitchenSink/build/android/bin/app.apk' as zip archive
HTH
R
It's working now. I didn't have the API 1.6. Downloaded all the available packages while I was there, and it's running now.
Thanks!
R
I'm getting a similar error, basically it says that classes.dex does not exist so I get a system error while compiling. Running on Windows though.
I've got the same problem. I've tried the "APIs 1.6 fix" and the "builder.py memory fix", but to no avail. Here's the trace I get (it's a little long, yes):
If you see [INSTALL_FAILED_MISSING_SHARED_LIBRARY] in the log it means you're not using the right Emulator. You must use a Google APIs emulator image. Those are designated as "Api X.X" on the Android test and launch screen.
Worked for me following the instructions! Thanks.
Using DDMS i found that Memory allocated to application is get increases as i am navigating screen by screen and after some time it crash application with force close message/Fail to load resources. Even i have remove all objects from window and after that assign null to it. i.e window.remove(viewname); viewname=null; window.close(); window=null. Please help Me OUT.
Which emulator are you launching? It needs to be "API 1.6"
Hello,
THe ones I have available are 1.6, 2.2 and APIs 2.2. All three give me the same error. I am downloading 2.1 API 7 right now to see if I see more options.
Anything else I should check?
Still no success with the 1.5 or 2.1 emulators.
Make sure you don't rename the KitchenSink project's directory. It needs to be the same name as in GitHub. A fix for that should show up in 1.4.0
Don,
By folder you mean the actual KitchenSink folder? What I did was to download the whole KitchenSink package, went to 1.3.x grabbed the KitchenSink folder that resided in there, and moved it to my local development folder.
R
That installation error is referring to Maps. You must run Kitchen Sink on an emulator that starts with Api e.g. "Api 1.6"
Hello,
I think I'm getting closer to get this to work. When the process stops, now it says:
[ERROR] Failed installing com.nolanwright.kitchensink: pkg: /data/local/tmp/app.apk [TRACE] Failure [INSTALL_FAILED_MISSING_SHARED_LIBRARY]
Full trace for the building process is at https://gist.github.com/gists/9b68bcd784500a32e7ac/download
Does anyone know what "shared library" it refers to?
-R
Your Answer
Think you can help? Login to answer this question!