App to Android Issue

The place to discuss anything and everything about running your LiveCode on Android

Moderators: Klaus, FourthWorld, heatherlaine, robinmiller, kevinmiller

cbarnhart
Livecode Opensource Backer
Livecode Opensource Backer
Posts: 48
Joined: Mon May 07, 2012 2:10 pm

App to Android Issue

Post by cbarnhart » Mon May 07, 2012 2:21 pm

I know I must just be missing something simple.
I have a simple app that I can test on the simulator and it works. I then create the keystore file for my key and add the path to the Android Standalone create menu. I create the standalone and try to install on my tablet and get "unable to install". So I tried the market and get invalid key signing. Does anyone have any suggestion where I can start to hunt down my problem? I figure it must be in the keysigning but I can not find my issue

jacque
VIP Livecode Opensource Backer
VIP Livecode Opensource Backer
Posts: 5139
Joined: Sat Apr 08, 2006 8:31 pm
Location: Minneapolis MN
Contact:

Re: App to Android Issue

Post by jacque » Mon May 07, 2012 5:29 pm

If you've correctly assigned the keystore to your app, LiveCode will ask you for the passwords while it's doing the build. If it doesn't then it thinks the app isn't being built with a key. Does it ask for the details of your keystore during the build? If not, I'd check the standalone settings again and make sure the popdown says "build with my key" and the path is correct.
Jacqueline Landman Gay | jacque at hyperactivesw dot com
HyperActive Software | http://www.hyperactivesw.com

cbarnhart
Livecode Opensource Backer
Livecode Opensource Backer
Posts: 48
Joined: Mon May 07, 2012 2:10 pm

Re: App to Android Issue

Post by cbarnhart » Mon May 07, 2012 8:01 pm

yes it does ask for keystore info and I supply the info and finishes with a "completed". Still the file will not run. I also tried a manual key signing with jarsigner and checked with aligntool. They all completed with no errors. Even after this it will not run with a manual transfer to a tablet and will not install from market. I am at a loss what to try next.

cbarnhart
Livecode Opensource Backer
Livecode Opensource Backer
Posts: 48
Joined: Mon May 07, 2012 2:10 pm

Re: App to Android Issue

Post by cbarnhart » Mon May 07, 2012 9:06 pm

When I try to install from the market, i receive the error "package files was signed incorrectly". Any ideas where I need to start looking?
Last edited by cbarnhart on Tue May 08, 2012 1:15 pm, edited 1 time in total.

jacque
VIP Livecode Opensource Backer
VIP Livecode Opensource Backer
Posts: 5139
Joined: Sat Apr 08, 2006 8:31 pm
Location: Minneapolis MN
Contact:

Re: App to Android Issue

Post by jacque » Mon May 07, 2012 9:10 pm

I'm afraid I don't know what could be wrong in that case. The one time I got the error, I had accidentally entered a password into the first dialog that was asking for the app id. But I suppose you aren't doing that.
Jacqueline Landman Gay | jacque at hyperactivesw dot com
HyperActive Software | http://www.hyperactivesw.com

andyh1234
Posts: 382
Joined: Mon Aug 13, 2007 4:44 pm
Location: Sale UK / FL USA
Contact:

Re: App to Android Issue

Post by andyh1234 » Thu May 10, 2012 10:24 am

If you already have an app on your device with the same id, this can cause this problem.

Try changing the app id as a test to see if this helps (i.e.. the com.developer.appname)

Sometimes when I'm running tests my devices will get stuck on one id and just not let me install anything, but just adding a '1' to the end fixes it.

cbarnhart
Livecode Opensource Backer
Livecode Opensource Backer
Posts: 48
Joined: Mon May 07, 2012 2:10 pm

Re: App to Android Issue

Post by cbarnhart » Thu May 10, 2012 1:17 pm

Great suggestion but that is not the issue. The problem I am having only occurs on the final build when I key sign the standalone. It runs through the debugging in emulation and on my tablet. But once KeySigned is will not install on the tablet or from the Market. So I guess my issue is the key signing or maybe in the standalone creation. I ran through the tutorials on LiveCode, but does anyone know of any good step by step documents? Or is there certain "must do" items I could have overlooked? For example does the stack need to reside in the particular directory structure to create properly?

Any suggestion would be helpful

andyh1234
Posts: 382
Joined: Mon Aug 13, 2007 4:44 pm
Location: Sale UK / FL USA
Contact:

Re: App to Android Issue

Post by andyh1234 » Thu May 10, 2012 1:39 pm

Thats a shame, I thought I had it then!

On my system the only way I can get it to work is to use...

com.developername.appname-dev while developing and...
com.developername.appname for the final release.

If I try to install the app with the same ID on a device I've used for testing, but signed with the release cert then I run into the issues you reported, so I thought it was worth a shot!

The only other thing I've had issues with it when entering the keystore id and password I have to get it right first time. If I press a backspace just once that will make it fail, but I guess you are past that stage.

If you want to try the package on a device that has never seen your dev copy to see if it does the same, I'm happy to try installing it on one of my devices if that helps at all.

Andy

jacque
VIP Livecode Opensource Backer
VIP Livecode Opensource Backer
Posts: 5139
Joined: Sat Apr 08, 2006 8:31 pm
Location: Minneapolis MN
Contact:

Re: App to Android Issue

Post by jacque » Thu May 10, 2012 6:48 pm

I think you're right about the keysign being the problem. There's quite a bit of info here:
http://developer.android.com/guide/publ ... gning.html

Did you make sure to set an expiration date well into the future? The suggested date is 25 years from now.

There may be something else wrong with the key you created. I think there's a verification command where you can test the validity but I didn't read the above page too carefully. If all else fails, I'd say just make a new key and try with that.

Also, completely delete all development versions of your app from the device before trying to install with a release version.
Jacqueline Landman Gay | jacque at hyperactivesw dot com
HyperActive Software | http://www.hyperactivesw.com

kodiaksoftware
Posts: 4
Joined: Wed Apr 18, 2012 3:24 am

Re: App to Android Issue

Post by kodiaksoftware » Sat May 26, 2012 1:13 am

We are having the same issue with keysigning from 5.5.

While google play accepts the signed app with no problem, it can't be installed on devices.
Even sideloading the app will not allow us to install the signed app, but if I go back to debug signing it works fine.

1. I have removed all debugging apps from all devices and still get the installation error.
2. I have attempted installs on virgin devices and still no luck
3. I reflashed a device and still have no luck
4. I have created new keystores and tried them all.
5. I have used Keytool to view the contents of the keystore and everything appears normal and correct.
6. I will be dead before any of the keys expire so that isn't the problem
7. I have followed every suggestion I could find on websites and forums.
8. Our Eclipse programmers have stood over my shoulder and tell me I'm doing everything correctly

My question is has anyone successfully gotten this to work
with 5.5?

Don

jacque
VIP Livecode Opensource Backer
VIP Livecode Opensource Backer
Posts: 5139
Joined: Sat Apr 08, 2006 8:31 pm
Location: Minneapolis MN
Contact:

Re: App to Android Issue

Post by jacque » Sat May 26, 2012 2:44 am

I just tried building an Android app again using 5.5 and was able to do it. I sideloaded it and it launched. I used my personal keystore, not the development one.

I noticed when I selected it from disk there was a popdown in the Open File dialog that offered "Java" or "All files". I used Java.

There were three dialogs during the build. The first was the keystore alias, the second for the keystore password and the third for the private key password. I'm sure you must have entered those since it won't build without them.

I'm not sure what to tell you, it works here.
Jacqueline Landman Gay | jacque at hyperactivesw dot com
HyperActive Software | http://www.hyperactivesw.com

jacque
VIP Livecode Opensource Backer
VIP Livecode Opensource Backer
Posts: 5139
Joined: Sat Apr 08, 2006 8:31 pm
Location: Minneapolis MN
Contact:

Re: App to Android Issue

Post by jacque » Sat May 26, 2012 2:57 am

Just a thought -- does the app try to launch and then fail? If so, could there be something in the scripts that's crashing? You could try debugging in the emulator (it isn't easy but it can be done.) Or you could add a few answer dialogs to various points in the startup, preopenstack, preopencard, etc. handlers that tell you whether it gets that far.
Jacqueline Landman Gay | jacque at hyperactivesw dot com
HyperActive Software | http://www.hyperactivesw.com

kodiaksoftware
Posts: 4
Joined: Wed Apr 18, 2012 3:24 am

Re: App to Android Issue - Solved

Post by kodiaksoftware » Sat May 26, 2012 4:11 am

Thank you jacque for trying to help us so quickly.

Here is what we found. Unfortunately it took three of us to almost 11PM on a Friday before a long holiday weekend to figure it out:
Since we set up a new machine to use for livecode android development, it had jdk 7 installed.
The jarsigner in jdk 7 has a problem leaving nulls in the certpath, so the apk is signed but with buried problems that only come to light during an install.
We downloaded JDK 6 and manually signed using jarsigner 1.6u32. and everything works correctly now.
That is probably why you longtime livecode programmers aren't having this problem but we newer developers are.

Don

I hope the OP will see if this is his problem.

jacque
VIP Livecode Opensource Backer
VIP Livecode Opensource Backer
Posts: 5139
Joined: Sat Apr 08, 2006 8:31 pm
Location: Minneapolis MN
Contact:

Re: App to Android Issue

Post by jacque » Sat May 26, 2012 4:29 am

I never would have guessed that. I'm sorry you were at it so long but I'm glad you found the problem, we'll all benefit. Is that a bug with the jdk that will be fixed, or is it something LiveCode needs to work around?

I hope your weekend is less stressful, it sounds like you've earned a break.
Jacqueline Landman Gay | jacque at hyperactivesw dot com
HyperActive Software | http://www.hyperactivesw.com

Nick Johnson
Posts: 16
Joined: Fri Jun 29, 2012 8:05 am

Re: App to Android Issue

Post by Nick Johnson » Fri Jun 29, 2012 8:18 am

You might be having two similar apps with same ID....
Change the ID of another app, may be your prob will get solved.....

Post Reply

Return to “Android Deployment”