Compilation for MIPS architecture, opendigux, rg350 handheld

Hi, this is my first post, so here we go

As I can see here https://lib.haxe.org/p/lime/7.5.0/changelog

“2.9.0 (01/22/2016)”
“Added MIPS and MIPSEL to architectures in tools”

So I guess, compiling for an rg350m machine, is in the realm of possible…

Here are the specs of the said machine:

CPU: [Ingenic JZ4770] 1 GHz MIPS processor

GPU: Vivante GC860, capable of OpenGL ES 2.0

RAM: 512 MB DDR2

System: Linux 3.x OpenDingux

So my question is, how is it achievable? What flag should I add to the lime or openfl compilation? Is there a workaround? Anything at all to make that happen? I hardly can find any information about it, except for the lime changelog page above which mention mips architecture…

FYI I have a linux desktop, if that can help

And here is a rather outdated tool chain I’ve found which I have successfully used to compile cmatrix for the rg350m https://boards.dingoonity.org/retro-game-350rg-350/(development)-how-to-compile-for-rg350-(help-needed)/ and then packaged into a .opk, it works

The cmatrix project in case you don’t know what that is github dot com /abishekvashok/cmatrix (sry I’m limited to 2 links…)

Any help, any lead/idea about how to go about it, is highly appreciated, thx in advance

I would also be interested. I’m trying to put together an environment to compile openfl projects for Miyoo Mini plus and RG nano but I’m having trouble understanding the needed config for a custom target and putting it all together. @calimero did you had luck in the meanwhile? do you might have some insight to share to achieve this?

1 Like

No, I gave up trying, too much hassle

Maybe you could try installing haxe and openfl and all that on the miyoo mini via the command line and compile the project on the console itself, since it’s linux based? That’s where I stopped trying, it was on a RG350 with an “experimental” network connection via wifi dongle… Maybe the miyoo mini is more capable/suited to do just that than the RG350

In the end I switched to SGDK, and I use it to make games for megadrive, so there’s no porting hassle as long as a megadrive emulator is available somewhere…

Most likely, you’ll need to look for defines exposed by hxcpp.

I searched for mention of mipsel in the hxcpp project, and I found that there’s a “GCW Zero” toolchain in hxcpp, which seems to be a Linux handheld that is MIPS architecture.

https://github.com/search?q=repo%3AHaxeFoundation%2Fhxcpp+mipsel&type=code

It looks like this toolchain may be enabled with the gcw0 define. Not sure if anything else is required. Not sure if other handhelds are supported at all. But maybe this will be enough to give someone a clue of what to search for to dig in some more.

Thank you @calimero and @joshtynjala for your quick replies and all the info!
The cool thing of Miyoo Mini is that the toolchain is easily available from a ready-to-use docker image: GitHub - shauninman/union-miyoomini-toolchain
As that image is based on a Debian system is also easy to extend and install all the haxe deps and openfl to have a dedicated full-fledged container env for this, but what i’m struggling to understand is how to tell haxe/openfl/lime (or whatever is the right tool for this) to use that toolchain to cross-compile.
I can see lot of examples of makefiles to setup the cross-compilation in a common g++/Make context: Making Games · TriForceX/MiyooCFW Wiki · GitHub
and even finished apps:
https:// github .com/ealang/pixel-reader/blob/master/Makefile

But i’m missing the knowledge on how i can write/port such more “common” compilation settings to an Haxe/Openfl/Lime configuration. I’m able to compile to a certain extent inside that container haxe/openfl projects (after installing all the required deps) but the result is x86 so i’m confused in what are the proper commands/settings to define a cross-compilation.
I can see the GCW Zero toolchain config and intuitively i think i can try to copy-paste and setup a Miyoo Mini toolchain config using the Makefiles above as a source of proper flags needed, but i think i’m missing a step on how to tell haxe/lime/openfl that it should use that as a toolchain

1 Like