Topic: Definitive Android Build Guide

Hi,

I'm just new to Maratis and I would like to try out deploying my project to Android. I read that there are somehow posts that mentioned that it is support but I can't find a definitive guide. Can someone please point out how to create those demos in Android build?

Thanks.

Re: Definitive Android Build Guide

Hi, and welcome to Maratis forum.

Unfortunately there is no fast and ready Android support,
the majority of the source code is compatible and some contributors managed to port to Android,
but not without putting their hands in the dirt.

If you are already experimented with Android software development,
you may want to try Dahnielson's fork of Maratis that is very close (or already able ?) compiling to Android :
https://github.com/dahnielson/Maratis

The future version of Maratis is also more Android friendly, but still highly experimental :
https://github.com/anael-seghezzi/Maratis-4

Re: Definitive Android Build Guide

Thanks anael for these resources, but it seems there's still no reference or how-to to properly build it with android and I'm really looking forward to trying Maratis out with it's light weight code and great built-in features.

Can you point me to the right direction?

P.S: Also, can I use VC 2008 or 2010 to build the engine code?

Last edited by wini (2015-07-26 05:25:16)

Re: Definitive Android Build Guide

Hey wini!

Building on Android is no standard feature afaik.
If you use Dahnielsons branch, you have to create a new CMake toolchain for the ARM toolchain that you get when installing the Android NDK.
Set some flags and see how far it gets when compiling stuff. You might have to replace some 3rdparty software with Android friendly ones, I don't know if everything will work out of the box. You also might want to turn off all executables and build the player/editor as well as MCore and MEngine static libraries. Dahnielsons branch uses SDL, which ships with ready made Android makefiles. You need to exclude it from the CMake build. If you got that, use ndk-build to compile the SDL version directly.

Then you need to write some code to a) Link all Maratis libraries + player statically into one .so file using the NDK with ndk-build b) To load this code into an Android app written in Java.

It should now run on any ARM based Android device. There is some additional magic involved in getting big data files for assets on Android which is necessary before this is a viable option for delivering a game (pack everything into the APK and unpack it at the first launch? Or download it from the web?).

This is all in all a heavy task, more so if you are a newcomer to Maratis (or any code base for that matter) which needs some coding to get it to work properly.

Cheers!

PS: I was using those toolchain files: https://github.com/Sponk/NeoEditor/tree … Toolchains for my own experiments
Disclaimer: I did not write those myself, read the credits in the file header for more information.

Re: Definitive Android Build Guide

Hey Thanks Sponk! smile Yes I was looking at your NeoEditor engine project as well while looking for more solutions but have not tried it yet. Looks really cool to have and build on Android these days as an option.