Search code examples
androideclipseandroid-emulatoradb

Failed to install apk on ICS 4.03 emulator


I can't install my apk on a API 4.0.3 ADV device from eclipse.

Here the data:

IDE Eclipse 3.6.2

Device Android 4.0.3 (API 15) Rev 2 WVGA800 Density 160 Heap 48 RAM 512 (tried 1024 as well)

I got this error:

Failed to install test.apk on device 'emulator-5554': EOF
[2012-02-28 09:18:11 - test] java.io.IOException: EOF
[2012-02-28 09:18:11 - test] Launch canceled!*

And the device disappeared from the DDMS screen.

NOTE: if I change WVGA800 to HVGA everything works!

Any solution to this ? Thanks


Solution

  • You can use adb command to install apk files to emulator/devices

    adb install test.apk
    

    set environmental varaible before using adb

    if you are using linux use this command

    export PATH=$PATH{}:/opt/android-sdk-linux/tools/:/opt/android-sdk-linux/platform-tools/
    

    or you can use relative path of the command like this

    /opt/android-sdk-linux/platform-tools/adb install test.apk