Compile Lakka and cores for specific target

The nightly builds have some specific platforms, such as the Pine A64 and Pine A64+. I am trying to compile specifically for the A64+.

Following the build documentation, this seems like the right place to start: DISTRO=Lakka PROJECT=Allwinner DEVICE=A64 ARCH=aarch64 make image

But how do I target the A64+?

And then how can I compile a new core for it?

There is an additional variable you can set: UBOOT_SYSTEM. Have a look here for the available systems.

I don’t own an A64 device and cannot test this, but this could be what you need:

DISTRO=Lakka PROJECT=Allwinner DEVICE=A64 ARCH=aarch64 UBOOT_SYSTEM=pine64-plus make image

You can compile a core for a device by manually building its corresponding package, here’s an example for the Parallel-N64 core:

DISTRO=Lakka PROJECT=Allwinner DEVICE=A64 ARCH=aarch64 scripts/build parallel-n64

1 Like

Thank you! I noticed there was something with U-Boot but didn’t know how to set it.

I’m now running into the problem that the build system can’t find a Mali 400 driver for aarch64. There seems to only be an armhf driver.





Regarding the core, do the libretro samples have a package? I’m trying to make my own core, so I need to know how to cross-compile and link.

Yes, there is no armhf driver in the Lakka repository for Mali 400. You need to build Lakka as 32-Bit or get the driver from somewhere else. As a side note, I have a device with a Mali 400 and performance with the libmali DRM driver is horrible, but your experience may be different.

What’s a libretro sample? You don’t need to manually setup cross-compiling when using the Lakka build system, it does this automatically.

I’m curious how well it works. I think I tried the nightly before and it was able to handle old 8/16-bit systems, using software. I would imagine that OpenGL (Mali) would be an improvement, which is why I am looking into accelerated cores.

Samples are here:

I just found this: Mali Driver - PINE64 This seems to be the 64-bit DRM driver for Mali 400. You could give this a try. Let me know how it goes!

Regarding the libretro samples, I’m sorry, I cannot help with that, I have never heard of it. What would this do if you added it to Lakka?

Thanks. I’ll try to have a look and see. I’m not sure if it will be compatible with GBM.

You can read about the samples here:

I’ve tested them in Retroarch (with Libretro) and that works. So, the next step is to get the core into Lakka to test.

If it’s a Wayland driver, wouldn’t that mean it supports GBM? Another side note: You will have to add some of the Wayland packages as dependencies for this driver in Lakka (add “wayland” and “wayland-protocols” in PKG_DEPENDS_TARGET if I remember correctly). Wayland is not actually used by Retroarch or any of the cores, but these drivers are linked against the Wayland libraries, so if they’re not present it will generate a runtime error.

For all that, I’d suggest creating a separate package for the driver (“libmali-test” or any other name).

Regarding the libretro samples, if it’s just a core like any other, just copy another core package as a template and modify it according to your needs.