I can't install apk from eclipse

I've installed eclipse in a new computer with windows 8, I've copy the workspace from my old PC and now I can open the projects and work with them normally, but when I try to install the apk in a device or in the emulator, appears an error in the console:

Installation failed due to invalid APK file! Please check logcat output for more details. Launch canceled!

This is the logcat:

> 05-30 13:11:54.054: W/PackageParser(3644): Unable to read AndroidManifest.xml of /data/local/tmp/J i A.apk
05-30 13:11:54.054: W/PackageParser(3644): java.io.FileNotFoundException: AndroidManifest.xml
05-30 13:11:54.054: W/PackageParser(3644):  at android.content.res.AssetManager.openXmlAssetNative(Native Method)
05-30 13:11:54.054: W/PackageParser(3644):  at android.content.res.AssetManager.openXmlBlockAsset(AssetManager.java:487)
05-30 13:11:54.054: W/PackageParser(3644):  at android.content.res.AssetManager.openXmlResourceParser(AssetManager.java:455)
05-30 13:11:54.054: W/PackageParser(3644):  at android.content.pm.PackageParser.parsePackageLite(PackageParser.java:649)
05-30 13:11:54.054: W/PackageParser(3644):  at com.android.defcontainer.DefaultContainerService$1.getMinimalPackageInfo(DefaultContainerService.java:144)
05-30 13:11:54.054: W/PackageParser(3644):  at com.android.internal.app.IMediaContainerService$Stub.onTransact(IMediaContainerService.java:102)
05-30 13:11:54.054: W/PackageParser(3644):  at android.os.Binder.execTransact(Binder.java:338)
05-30 13:11:54.054: W/PackageParser(3644):  at dalvik.system.NativeStart.run(Native Method)
05-30 13:11:54.054: W/DefContainer(3644): Failed to parse package
05-30 13:11:54.062: I/ApplicationPolicy(187): isApplicationInstallationEnabled
05-30 13:11:54.062: W/PackageManager(187): verifying app can be installed or not
05-30 13:11:54.062: W/PackageParser(3644): Unable to read AndroidManifest.xml of /data/local/tmp/J i A.apk
05-30 13:11:54.062: W/PackageParser(3644): java.io.FileNotFoundException: AndroidManifest.xml
05-30 13:11:54.062: W/PackageParser(3644):  at android.content.res.AssetManager.openXmlAssetNative(Native Method)
05-30 13:11:54.062: W/PackageParser(3644):  at android.content.res.AssetManager.openXmlBlockAsset(AssetManager.java:487)
05-30 13:11:54.062: W/PackageParser(3644):  at android.content.res.AssetManager.openXmlResourceParser(AssetManager.java:455)
05-30 13:11:54.062: W/PackageParser(3644):  at android.content.pm.PackageParser.parsePackageLite(PackageParser.java:649)
05-30 13:11:54.062: W/PackageParser(3644):  at com.android.defcontainer.DefaultContainerService$1.getMinimalPackageInfo(DefaultContainerService.java:144)
05-30 13:11:54.062: W/PackageParser(3644):  at com.android.internal.app.IMediaContainerService$Stub.onTransact(IMediaContainerService.java:102)
05-30 13:11:54.062: W/PackageParser(3644):  at android.os.Binder.execTransact(Binder.java:338)
05-30 13:11:54.062: W/PackageParser(3644):  at dalvik.system.NativeStart.run(Native Method)
05-30 13:11:54.062: W/DefContainer(3644): Failed to parse package
05-30 13:11:54.062: W/ActivityManager(187): No content provider found for permission revoke: file:///data/local/tmp/J i A.apk

If I try to export the application to generate the apk file, appears a dialog that says "Failed to export application".

Any idea to solve this? I can't test my app or generate the apk in anyway.


Check the target SDK for the android app and make sure you have that SDK version installed. You can change it in project properties.

链接地址: http://www.djcxy.com/p/24698.html

上一篇: 未能在设备的模拟器上安装apk

下一篇: 我无法从eclipse安装apk