Android builds with Mac does not install on Android devices.

If you open a folder instead of an individual file, there will be a sidebar on the left that lists the files in the folder, so you quickly open the text files.  You can also right click to rename, delete etc.  If the sidebar isn’t showing then you can do a View->Side Bar->Show Side Bar.

Rob

Thanks man, you are SO awesome!

Sorry for the LONG delay. I got to manage to get back to this again, finally.

I did build the hello world sample and it did indeed install OK but still my builds are not getting installed. I tried to install via adb install command and got this from OS X’s Terminal:

Failure [INSTALL_PARSE_FAILED_CERTIFICATE_ENCODING]

and logcat logged this while I was installing:

D/AndroidRuntime(29160): D/AndroidRuntime(29160): \>\>\>\>\>\> AndroidRuntime START com.android.internal.os.RuntimeInit \<\<\<\<\<\< D/AndroidRuntime(29160): CheckJNI is OFF D/AndroidRuntime(29160): Calling main entry com.android.commands.pm.Pm W/ActivityManager( 238): No content provider found for permission revoke: file:///data/local/tmp/SuperHungryMonsters.apk W/ActivityManager( 238): No content provider found for permission revoke: file:///data/local/tmp/SuperHungryMonsters.apk W/PackageParser( 238): Exception reading /data/app/vmdl669478898.tmp W/PackageParser( 238): java.io.IOException: Entry is not named W/PackageParser( 238): at java.util.jar.InitManifest.initEntries(InitManifest.java:60) W/PackageParser( 238): at java.util.jar.Manifest.read(Manifest.java:221) W/PackageParser( 238): at java.util.jar.Manifest.\<init\>(Manifest.java:120) W/PackageParser( 238): at java.util.jar.JarFile.getManifest(JarFile.java:296) W/PackageParser( 238): at android.content.pm.PackageParser.collectCertificates(PackageParser.java:536) W/PackageParser( 238): at com.android.server.pm.PackageManagerService.installPackageLI(PackageManagerService.java:7269) W/PackageParser( 238): at com.android.server.pm.PackageManagerService.access$1500(PackageManagerService.java:166) W/PackageParser( 238): at com.android.server.pm.PackageManagerService$5.run(PackageManagerService.java:5699) W/PackageParser( 238): at android.os.Handler.handleCallback(Handler.java:605) W/PackageParser( 238): at android.os.Handler.dispatchMessage(Handler.java:92) W/PackageParser( 238): at android.os.Looper.loop(Looper.java:154) W/PackageParser( 238): at android.os.HandlerThread.run(HandlerThread.java:60) D/dalvikvm( 238): GC\_EXPLICIT freed 700K, 47% free 16664K/31395K, paused 12ms+10ms D/AndroidRuntime(29160): Shutting down VM D/dalvikvm(29160): GC\_CONCURRENT freed 136K, 42% free 593K/1024K, paused 0ms+0ms I/AndroidRuntime(29160): NOTE: attach of thread 'Binder Thread #3' failed W/ThrottleService( 238): unable to find stats for iface rmnet0

My Java is 1.6. When I run the java -version command in Terminal it returns this:

java version "1.6.0\_51" Java(TM) SE Runtime Environment (build 1.6.0\_51-b11-457-11M4509) Java HotSpot(TM) 64-Bit Server VM (build 20.51-b01-457, mixed mode)

I don’t think it be my Java because I did an Android build with Unity recently and I assume it uses my JRE as well.

What can I do to fix this finally?

Thanks.

and here is my Android build dialogue box:

Screen_Shot_2013_11_18_at_10_24_21_PM.pn

My OS version is 10.8.4 and I’m trying install my app on a HTC Amaze 4G. My Corona simulator version is 2013.1135 (2013.6.3) and my phone’s Android version is 4.0.3 and I posted info about my Java version earlier.

I’ve seen that another problem could be folder names, folder names that I have are:

menu music juice sfx &nbsp;

Also my build.settings file is:

settings = { iphone = { plist = { CFBundleIconFile = "Icon.png", CFBundleIconFiles = { "Icon.png" , "Icon@2x.png" , "Icon-72.png" , "Icon-72@2x.png" , "Icon-Small-50.png" , "Icon-Small.png" , "Icon-Small@2x.png" }, UIAppFonts = { "Tahoma.ttf" } }, }, orientation = { default = "portrait", supported = { "portrait", "portraitUpsideDown" } }, }

and I’m building to Desktop folder of my Mac.

I’ve seen another topic’s suggestion and tried swapping my build.settings file to the one from hello world, same error.

I’m willing to hand over the build file, if you want.

* Bump *

Have you read this thread?

 

http://forums.coronalabs.com/topic/29712-android-failure-install-parse-failed-certificate-encoding/

It’s got some suggestions to try and determine if is a problem with your Java setup or not.   Also try doing a:

adb uninstall com.lk.shm

before you do your adb install.

Rob

Thanks Rob for the reply.

I actually did read that topic and repeated posts that I’ve made before your reply was an effort to provide answers to questions people asked the OP (original poster) of that topic in order to help the process.

Please do correct me if I’m wrong but I think the OP of that topic did not reach an answer, right?

Did you try the  uninstall call?

Hi,

Sorry for the long delay, again. Can’t work as good as before.

I tried adb uninstall and it just said “Failed” in the Terminal. So I removed them manually via the phone.

I upgraded to Mavericks and when I tried to run my game in Corona Simulator it said that it doesn’t have Java, so I let it to download and checked via Java -version and it said 1.6.0_65.

I tried to build again and install via adb install, replied the same “INSTALL_PARSE_FAILED_CERTIFICATE_ENCODING” error.

What should I do?

In another topic there was a suggestion of signing the apk file manually, I did that and still the same INSTALL_PARSE_FAILED_CERTIFICATE_ENCODING error is what I get.

I’m to the point that would be glad to give you guys my whole project, if you want.

Thanks.

I renamed the apk file to zip and extracted it and there was two interesting things that caught my attention:

  1. There was a file named “icon” that has no extension and it’s size is zero. Is this normal?

  2. I have some files that I have folders with same name. For example. I have sfx.lua and a folder called sfx in the same structure. Can they make problem?

  3. I remember there was a problem with case sensitivity in Android builds, do they still exist to this day and age?

Apparently problem was not related to my folder names as I changed them and problem persists.

Why is this bug this hard to find? It’s so frustrating, everytime I want to work on this game, I get stuck with this bug and can’t get anything done.

Folder names can cause problems, but having an sfx folder and an sfx.lua shouldn’t be an issue.  Folder names with non-ASCII characters can cause issues (and not just within the project).  On iOS, a folder name “resources” causes issues.

Android (and iOS) devices file systems are case sensitive, Windows and the Mac’s filesystems are not.  But this would result in your app getting a black screen (crashing) when you run it and the error would be obvious in your adb logcat.

You are having a signing issue, so sending us your project isn’t going to do much good.  With your upgrade to Mavericks and the changes to java, humor me and try to build and install the Hello World sample app.  Take screen shots if the Corona build screen before you click the build button so I can see what’s set there.

Rob

Hi man,

First of all let me thank you for your constant support.

Following your advice, here is screenshot of my build window:

[media]https://www.dropbox.com/s/1r4t9ho2kvdl1ng/Screenshot%202013-12-01%2023.14.07.png[/media]

And results is that it got installed with “Success” in Terminal.

What now?

Were you able to use _ adb install _ to install the app on your device?

If so, then there is a problem with your  app some where.  If that failed, we have a keystore problem, however, your screen shot shows you are using a debug keystore  and that shouldn’t be generating any errors.

What is the result of the command line command:   java -version

Thanks

Rob

Yes, I installed the HelloWorld app with adb install.

Java -version results this:

java version "1.6.0\_65" Java(TM) SE Runtime Environment (build 1.6.0\_65-b14-462-11M4609) Java HotSpot(TM) 64-Bit Server VM (build 20.65-b04-462, mixed mode)

Then there is an issue with your app itself.  If you want to zip it up and get it to me somehow (uploading to dropbox and sending me a link to it would be fine), then I’ll see if I can see what’s causing the problem.

Rob

That would be splendid. How can I give the project to you privately? Can’t seem to find PM feature anywhere.