Porting Android apps to SuperZaxxon


EssoAir

Well-Known Member
Joined
Dec 13, 2012
Messages
1,822
Location
Knoxville/Seattle
Since Android is a Linux distro, and so is SuperZaxxon (I'm aware that is extremely over simplified) what is the problem with simply porting Android apps to PND? (or even DEB)


If anyone knows what the real limiting factors are, please let me know


Thanks!


CJ
 
Last edited by a moderator:
Also, most Android apps use the Dalvik virtual machine. Some javalayer, that is not easily available on normal linux.


If your app has sourcecode available and you can rip out the javastuff, it might be possible to port an Androidapp.
 
There is at least one recent topic on this. Please do a bit of research.
 
Interesting. Would be neat to have Tapatalk and Opera directly running from PandoraOS.
Based on the http://wiki.maemo.org/Apkenv/Game_Compatibility compatibility wiki it seems only few native (not dalvik) programs run under apkenv.


Still a cool piece of tech: provides the runtime environment (bionic libraries) which android native games expect. Programs requiring networking api or other android kernel features won't work.
 
Last edited by a moderator:
just setting up a new virtualbox image ... want to try apkenv if i get some time
 
Well I tried to compile it on Pandora, seems you have to work around a few things - I didn't get so far. Basically it's intended for Meamo/Meego and expects either SDL_GLES or SDL with internal GLES support. So this is what we need to work around on Pandora, although Didn't pickle have a special SDL/GLES wrapper on Pandora?

Anyway yeah didn't get it to compile but shouldn't be too bad for someone with a little time...?
 
just sent notaz some info. already have it working. at least the rabbit game.


its a bit more work than just compiling, but well most of the time inspent figuring out what works how :)
 
Basically it's intended for Meamo/Meego and expects either SDL_GLES or SDL with internal GLES support.
Wow, so it looks like an SDL app to the host system, and like a native android host to the guest app... using SDL to setup the screen. And the guest app is just doing normal OpenGL ES stuff without know it is running via SDL. /Blink/
 
it works like this: first it loads an android native compiled library, then links it dynamically and replaces all functions from the android libraries wih the matching functions found on the host system.


for all libraries that do not have an exact replacement found, wrappers need to be implemented; apkenv did so with gles and gles2 and some others. thats probably because the library names in android and the host system do not match, but i'm unsure as of yet.


sdl is not required to have it running. it's primary use is to initialize the gl context and have proper sound and input handling. all this could easily be replaced with something else.


the real pain with this approach is, that you need to implement a supporting module for each .apk you want to run natively. this is because you need to map the java function calls (JNI) to something the host system understands and give back something the caller is happy with.


the author gives some examples and currently his sample .apk is working on the pandora. i'm planning to create a module to get unity's angrybots working, which could then hopefully be used to run unity based games natively on the pandora.
 
i need to take a look at opera if that even works, though i think most of the apps are using native interface stuff which will just now work with that approach.

just attaching a pic i've made running the rabbit game 2.

 

apkenv.jpg
 
just attaching a pic i've made running the rabbit game 2.
Excellent work and thanks for the explanation. One thing confuses me: are these dalvik programs or native apps? If native, why are they using java / JNI?
 
just attaching a pic i've made running the rabbit game 2.
Excellent work and thanks for the explanation. One thing confuses me: are these dalvik programs or native apps? If native, why are they using java / JNI?

I could be wrong here, but what i remember is, that you at least need to have a java STUB that loads your native application.


also some APIs are likely not available natively but only in java.


that's the way it is on iOS, too. you can use c/c++ but you always need to write objective-c if you want to use functions from the iOS API.
 
Last edited by a moderator:
just some update ... got fruit ninja running. here again, if an apk works or not, also depends on its version. fruit ninja 1.5.4 for example works, whereas some newer version doesnt. also the angry birds space module gives me some segfaults, which i'm currently investigating.

I've already contacted the original author about the pandora port and we're probably going to integrate the pandora port into the mainline when he's done some changes to his current version.

i've also opened a github account and pushed my changes there if anyone's interested. no documentation about the pandora yet, but that's going to follow. https://github.com/crowriot/apkenv
 
Back
Top