APK builds and installs but won't run
Moderators: FourthWorld, heatherlaine, Klaus, kevinmiller, robinmiller
APK builds and installs but won't run
Hi there!
I've just started with LiveCode and am still getting familar with various aspects such as databases and mobile functions. To play with the latter I hooked up my Sony Z1 Compact. After some initial problems I finally got the stack to install on the Z1. However it won't run. I can see a screen flicker (presumably it starts up then dies immediately). I believe that the problem is somewhere in logcat, possibly this "No content provider". I've read about the /data/local directory but since the device isn't rooted (and I don't really want to either), I can't even see that directory. Any ideas? LCC 6.6.2
W/ActivityManager( 998): No content provider found for permission revoke: file:///data/local/tmp/file9wZZPU
I've just started with LiveCode and am still getting familar with various aspects such as databases and mobile functions. To play with the latter I hooked up my Sony Z1 Compact. After some initial problems I finally got the stack to install on the Z1. However it won't run. I can see a screen flicker (presumably it starts up then dies immediately). I believe that the problem is somewhere in logcat, possibly this "No content provider". I've read about the /data/local directory but since the device isn't rooted (and I don't really want to either), I can't even see that directory. Any ideas? LCC 6.6.2
W/ActivityManager( 998): No content provider found for permission revoke: file:///data/local/tmp/file9wZZPU
Michel J.L. van der Kleij
Coding to help stray animals in the Philippines
Albert Foundation - http://albert.tukcedo.nl
Aklan Animal Rescue & Rehabilitation Center - http://aarrc.tukcedo.nl
Coding to help stray animals in the Philippines
Albert Foundation - http://albert.tukcedo.nl
Aklan Animal Rescue & Rehabilitation Center - http://aarrc.tukcedo.nl
-
- VIP Livecode Opensource Backer
- Posts: 3901
- Joined: Sat Mar 24, 2007 2:54 am
- Location: Palo Alto
Re: APK builds and installs but won't run
Hi Tukcedo,
Have you tried with just a "Hello world" example on the Z1?
Probably best to start there, then deal with added code.
Simon
Have you tried with just a "Hello world" example on the Z1?
Probably best to start there, then deal with added code.
Simon
I used to be a newbie but then I learned how to spell teh correctly and now I'm a noob!
-
- Posts: 192
- Joined: Tue Mar 11, 2014 12:57 pm
Re: APK builds and installs but won't run
A good demo to try is:
http://forums.livecode.com/viewtopic.ph ... id#p107177
Simply extract the mgscrollerazindexdemo.zip from the zip file, and test in LC via USB - it works straight away on my Android phone.
http://forums.livecode.com/viewtopic.ph ... id#p107177
Simply extract the mgscrollerazindexdemo.zip from the zip file, and test in LC via USB - it works straight away on my Android phone.
Re: APK builds and installs but won't run
Good tip to try a simple Hello World: that worked. But now I'm left with: what part of the code that I added above the simple 1 button it doesn't like? I find this really puzzling to be honest. Where do I go from here?
Michel J.L. van der Kleij
Coding to help stray animals in the Philippines
Albert Foundation - http://albert.tukcedo.nl
Aklan Animal Rescue & Rehabilitation Center - http://aarrc.tukcedo.nl
Coding to help stray animals in the Philippines
Albert Foundation - http://albert.tukcedo.nl
Aklan Animal Rescue & Rehabilitation Center - http://aarrc.tukcedo.nl
Re: APK builds and installs but won't run
Maybe you could open Eclipse and see the log for that device to see if there is some useful info.
-
- VIP Livecode Opensource Backer
- Posts: 3901
- Joined: Sat Mar 24, 2007 2:54 am
- Location: Palo Alto
Re: APK builds and installs but won't run
Hi Tukcedo,
Go through your code and make sure you haven't used any iOS only commands/functions. There are plenty of them.
Good to hear you can run apps on the Z1.
Simon
Go through your code and make sure you haven't used any iOS only commands/functions. There are plenty of them.
Good to hear you can run apps on the Z1.
Simon
I used to be a newbie but then I learned how to spell teh correctly and now I'm a noob!
Re: APK builds and installs but won't run
This is the weird thing: it's just REALLY simple code. Most not even working yet (just started ...), so it's a bunch of (code-less) text entry fields, couple of buttons. Uses SQLite (which works fine in the IDE). If THIS doesn't even work I fear the worst for when I dig in. I'll try and expand the Hello World a little but I'm truly in the dark here
Michel J.L. van der Kleij
Coding to help stray animals in the Philippines
Albert Foundation - http://albert.tukcedo.nl
Aklan Animal Rescue & Rehabilitation Center - http://aarrc.tukcedo.nl
Coding to help stray animals in the Philippines
Albert Foundation - http://albert.tukcedo.nl
Aklan Animal Rescue & Rehabilitation Center - http://aarrc.tukcedo.nl
-
- Livecode Opensource Backer
- Posts: 447
- Joined: Mon Jan 23, 2012 12:46 pm
Re: APK builds and installs but won't run
Tukcedo wrote: Uses SQLite (which works fine in the IDE). If THIS doesn't even work I fear the worst for when I dig in. I'll try and expand the Hello World a little but I'm truly in the dark here
Is SQLlite checked in your standalone setting? Also probably Allow external storage.
--Sefro
Re: APK builds and installs but won't run
Bingo! Added fields and buttons, everything still ran. However, then I checked "Standalone Application Settings" -> Android -> "Externals/SQLite" and it stopped working!
I haven't actually added any of the revXXXX database calls yet, but would these still work leaving that checkbox cleared?
I haven't actually added any of the revXXXX database calls yet, but would these still work leaving that checkbox cleared?
Michel J.L. van der Kleij
Coding to help stray animals in the Philippines
Albert Foundation - http://albert.tukcedo.nl
Aklan Animal Rescue & Rehabilitation Center - http://aarrc.tukcedo.nl
Coding to help stray animals in the Philippines
Albert Foundation - http://albert.tukcedo.nl
Aklan Animal Rescue & Rehabilitation Center - http://aarrc.tukcedo.nl
-
- VIP Livecode Opensource Backer
- Posts: 3901
- Joined: Sat Mar 24, 2007 2:54 am
- Location: Palo Alto
Re: APK builds and installs but won't run
Hi Tukcedo,
I can assure you that SQLite and mySQL do work on mobile (iOS and Android).
Are you including a database with your stack or building it on the fly via liveCode?
specialFolderPath "documents" should be used in either case as a db included via the Copy Files will end up compressed in specialFolderPath "engine" and you don't want to decompress every time you use it, look it up in the dictionary.
Simon
I can assure you that SQLite and mySQL do work on mobile (iOS and Android).
Are you including a database with your stack or building it on the fly via liveCode?
specialFolderPath "documents" should be used in either case as a db included via the Copy Files will end up compressed in specialFolderPath "engine" and you don't want to decompress every time you use it, look it up in the dictionary.
Nopebut would these still work leaving that checkbox cleared?
Simon
I used to be a newbie but then I learned how to spell teh correctly and now I'm a noob!
Re: APK builds and installs but won't run
Thanks Simon, that may be the problem then as I had them located in "Home"! Incidentally, you also answered a question I had about how to distribute a database along with the package. I'll give it another try later.
Michel J.L. van der Kleij
Coding to help stray animals in the Philippines
Albert Foundation - http://albert.tukcedo.nl
Aklan Animal Rescue & Rehabilitation Center - http://aarrc.tukcedo.nl
Coding to help stray animals in the Philippines
Albert Foundation - http://albert.tukcedo.nl
Aklan Animal Rescue & Rehabilitation Center - http://aarrc.tukcedo.nl
Re: APK builds and installs but won't run
Hmmm I changed the path to "documents" but as soon as I use the SQLite checkbutton it bombs out again. Did a filter on *.E and name of my Identifier and then I believe the below is the culprit:
Code: Select all
E/dalvikvm( 8134): dlopen("/data/app-lib/nl.tukcedo.war-2/librevdb.so") failed: dlopen failed: "/data/app-lib/nl.tukcedo.war-2/librevdb.so" is too small to be an ELF executable
Michel J.L. van der Kleij
Coding to help stray animals in the Philippines
Albert Foundation - http://albert.tukcedo.nl
Aklan Animal Rescue & Rehabilitation Center - http://aarrc.tukcedo.nl
Coding to help stray animals in the Philippines
Albert Foundation - http://albert.tukcedo.nl
Aklan Animal Rescue & Rehabilitation Center - http://aarrc.tukcedo.nl
-
- Livecode Opensource Backer
- Posts: 447
- Joined: Mon Jan 23, 2012 12:46 pm
Re: APK builds and installs but won't run
Have you tried checking write external storage as well? I seem to remember needing that permission to get it working.....
Re: APK builds and installs but won't run
Tried that too just now, no luck ...
Michel J.L. van der Kleij
Coding to help stray animals in the Philippines
Albert Foundation - http://albert.tukcedo.nl
Aklan Animal Rescue & Rehabilitation Center - http://aarrc.tukcedo.nl
Coding to help stray animals in the Philippines
Albert Foundation - http://albert.tukcedo.nl
Aklan Animal Rescue & Rehabilitation Center - http://aarrc.tukcedo.nl
Re: APK builds and installs but won't run
The problem is in the APK file. The APK file is just a zip file, try to unzip it and you'll get the following folders:
- assets (containing accessories file)
- lib/armeabi/
- META-INF
- res
Livecode Wiki: http://livecode.wikia.com
My blog: https://livecode-blogger.blogspot.com
To post code use this: http://tinyurl.com/ogp6d5w
My blog: https://livecode-blogger.blogspot.com
To post code use this: http://tinyurl.com/ogp6d5w