Oh so frustrating... apk preparation failed

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

Moderators: FourthWorld, heatherlaine, Klaus, kevinmiller, robinmiller

Post Reply
Jim Mac
VIP Livecode Opensource Backer
VIP Livecode Opensource Backer
Posts: 54
Joined: Wed Jun 28, 2006 9:22 pm

Oh so frustrating... apk preparation failed

Post by Jim Mac » Wed May 13, 2015 12:13 am

:x
I have never been able to get Android versions of my apps deployed from a Windows PC. I'm sure I've tried absolutely everything suggested by all the posts I could find going back years. I really need help so thought I'd try here.

The particulars:
1)SDK Manager: (installed items)
Tools> Android SDK Tools > 24.2
Tools> Android SDK platform Tools > 22
Tools> Android SDK Build Tools > 20
Android 4.1.2 (API 16)> all
Android 2.3.3 (API 10)> all
Android 2.2 (API 186)> all
Extras > all
2)Preferences>Mobile Support
SDK Root path correct
JDK path correct
3) Standalone Settings
Sign for development only
Allow External Storage
Minimum Adroid versin 2.3.3
No icon
4) Users>xxxx>.android
deleted debug.keystore

Nothing works.
Have completely reinstalled the SDK twice and rebuilt simulators a dozen times.
Have tried older versns of LC (6.5, 7.0.3 and 7.0.4)
Followed the "Day of Code" Android depoyment video
Running Windows 7 Pro
Am going nuts...

If my iMac weren't in the shop I'd get this working there(in a couple of hours?) but I'm dead in the water for a while and need to demo an Android versionof what I've been working on so we can start to think about hardware options.....HELP?

paul_gr
Posts: 319
Joined: Fri Dec 08, 2006 7:38 pm

Re: Oh so frustrating... apk preparation failed

Post by paul_gr » Wed May 13, 2015 5:29 am

Hi Jim,
Try an earlier version of Android SDK Build-tools.
My version is 19.0.3.
After you do this can you get LC to output an APK using save as standalone?
-- see attached shot of my Android SDK manager...
sdk manager setup.png
My setup is
Windows 7 Pro
Android root is C:/android/sdk
JDK version is jdk1.7.0_17
LC 7.0.4

As long as you can see the JDK path in Preferences >> Mobile Support, it should be available.

I always build the apk using "Save as standalone", then transfer the apk to a device, because the Android simulators are very slow.
Don't worry if your "test" button on LC's taskbar is greyed out -- it usually doesn't work for me...

Paul
Last edited by paul_gr on Wed May 13, 2015 8:20 pm, edited 1 time in total.

MaxV
Posts: 1580
Joined: Tue May 28, 2013 2:20 pm
Contact:

Re: Oh so frustrating... apk preparation failed

Post by MaxV » Wed May 13, 2015 3:35 pm

Livecode Wiki: http://livecode.wikia.com
My blog: https://livecode-blogger.blogspot.com
To post code use this: http://tinyurl.com/ogp6d5w

jacque
VIP Livecode Opensource Backer
VIP Livecode Opensource Backer
Posts: 7393
Joined: Sat Apr 08, 2006 8:31 pm
Contact:

Re: Oh so frustrating... apk preparation failed

Post by jacque » Wed May 13, 2015 5:29 pm

You need the debug keystore to sign for development. I have never deleted that so I don't know if it is regenerated automatically but if it is missing you won't be able to build.
Jacqueline Landman Gay | jacque at hyperactivesw dot com
HyperActive Software | http://www.hyperactivesw.com

Jim Mac
VIP Livecode Opensource Backer
VIP Livecode Opensource Backer
Posts: 54
Joined: Wed Jun 28, 2006 9:22 pm

Re: Oh so frustrating... apk preparation failed

Post by Jim Mac » Wed May 13, 2015 8:44 pm

Thanks all for advice. No luck yet.
Am going to do another fresh install of Android SDK , following exactly the advice from the wiki.....
If that deosn't work, I don't know where to turn.
Jim

Jim Mac
VIP Livecode Opensource Backer
VIP Livecode Opensource Backer
Posts: 54
Joined: Wed Jun 28, 2006 9:22 pm

Re: Oh so frustrating... apk preparation failed

Post by Jim Mac » Thu May 14, 2015 7:01 pm

:x i'M OFFICALLY GIVING UP. :x
I get my Mac back today (actually a brand new one as hard to justify pouring as much $$ as my old one needs to be resuscitated). If I can get an Android app saved on the new machine, I'll try to see where the differences are between SDK installs
I frankly cannot believe I'm having trouble with this. I've used older Android Installlers, older LC versions, etc. with no luck. Must be something with my work PC... though I have no idea what it could be...

Jim Mac
VIP Livecode Opensource Backer
VIP Livecode Opensource Backer
Posts: 54
Joined: Wed Jun 28, 2006 9:22 pm

SOLVED: Re: Oh so frustrating... apk preparation failed

Post by Jim Mac » Fri May 15, 2015 6:29 pm

:D SOLVED: :D though have no real idea why.
Got notice of LC 7.0.5 update and installed 7.0.5 Commercial. Made sure everythign was pointing to the correct places. Accepted defaults for "Standalone Application Settings" with "Sign for Development only" and voila.... Application Successfully Saved. Step 1 okay.

Copied the app to my Android device... took a while to remember how to do that... and lo and behold. I have my app on my device. Step 3 Okay.

:? Nothing's ever perfect of course. App doesn't run in simulator. Looks like it's starting and then shuts down. Step 2.. not so okay.
That I can live with.

Jim

Jim Mac
VIP Livecode Opensource Backer
VIP Livecode Opensource Backer
Posts: 54
Joined: Wed Jun 28, 2006 9:22 pm

Re: Oh so frustrating... apk preparation failed

Post by Jim Mac » Wed May 27, 2015 8:11 pm

....and... unsolved. Failure back. Harumph! 8.0 DP2 does fine but other oddities there.

Post Reply