Hello,
I’ve got a problem with the android target.
I tried to build my first project for Android (lime test android -emulator).
I could compile without any problem, it starts the emulator with no issues but when it’s time to run I get an error.
I was thinking it could be my project issue so I’ve got the PiratePig example set up and I’ve built that.
I started the emulator (emulator -adv mytestemulator) and after I launched the test (lime test android -emulator)
No problem with the compiling but in the end the same error.
This is it:
BUILD SUCCESSFUL
Total time: 11 seconds
3241 KB/s (6795634 bytes in 2.047s)
pkg: /data/local/tmp/PiratePig-debug.apk
Failure [INSTALL_FAILED_CONTAINER_ERROR]
rm failed for -f, Read-only file system
Starting: Intent { act=android.intent.action.MAIN cmp=org.openfl.samples.piratepig/.MainActivity }
Error type 3
Error: Activity class {org.openfl.samples.piratepig/org.openfl.samples.piratepig.MainActivity} does not exist.
lime test android -emulator 578,84s user 19,55s system 170% cpu 5:51,46 total
I’ve already read that topic on stackoverflow and I’ve already put the memory to 1024 (some people talk about keeping power of 2 numbers because sometimes it gives problem otherwise).
Also I’ve checked the SD is RW (using adb shell and check the FSs on the virtual machine).
It is read-writable, but some people suggests to force a remount. I’ve done that as well.
I’ve set the default install to SD and internal adb shell pm setInstallLocation 1 (1 = internal, 2 = SD, 0 =Auto)
but it doesn’t matter, still the same ERROR.
I will look deeper on google, but since it is not a critical need for me now (it will be when I have to deploy anyway), I’m not in a hurry
Black screen but I’ve heard the music. Anyway, it doesn’t work but IT IS installed.
So yes, it was the config.
Was it ignoring the device settings?
Maybe it’s just my problem the unwriteble SD.
I will check on this and update the thread if I find out.
Just to let you know it shows this
BUILD SUCCESSFUL
Total time: 11 seconds
3167 KB/s (6795630 bytes in 2.095s)
pkg: /data/local/tmp/PiratePig-debug.apk
Success
rm failed for -f, Read-only file system
Starting: Intent { act=android.intent.action.MAIN cmp=org.openfl.samples.piratepig/.MainActivity }
lime test android -emulator 20,31s user 1,96s system 16% cpu 2:16,87 total
What is the remove that fails because read-only system?
Still working on the SD?
You might try a newer Android API version (not sure that would help), that you might try an X86 processor for the emulator, and, I’m not sure if there might be other settings that interact with the “host GPU” setting, which is essential for OpenGL ES 2 support to work properly. Please let us know if you make progress, and helping is important
I’ll try later for sure both ways and let you know.
Also I want to take the opportunity to thank you again for the support but especially for your work. I’m having a lot of fun and challenge learning and playing with OpenFL.
Thanks a lot mate, you are a great man.
I compile with no issues, the app come to the emulator with the following commands
terminal1
cd to/your/androidsdk/
emulator -avd adtest
terminal2
cd to/your/project
lime test android -emulator -debug
what I get is a blank screen
I can see the background color in one screen when I “draw” a Bitmap rotated (I can see the triangles on the edges colored as the bgcolor).
I suppose every sprite get blitted black.
I’ve successfully used Android apps on an x86 emulator, though a bummer that they didn’t make that work properly for AMD processors, so totally subjective
I’m guessing that Genymotion does not use “host GPU” quite the same as the normal emulator, and thereby must be having a GL error of some kind