Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
lr-mgba segfaults
With default 3.0 installation lr-mgba segfaults on any GBA rom on my OPi PC, while lr-gpsp and lr-vba-next works OK. Tried updating it from source but that did not help, every rom crashes even before displaying GBA bios logo.

Did anyone else noticed this?
Yes, we've seen it and switching to GPSP was the solution. We'll put on todo list.
Thanks, will wait for proper resolution.

On 2.5 mgba had the best performance, and found only 1 game that did not work well (Big Mutha Truckers). Now tried Baldur's Gate: DA with both gpsp and vba-next and found them choppy (gpsp - audio + video, vba-next - video).
OK, recompiled and tested from SSH, seems to be working with uncompressed .gba roms
(12-29-2016, 06:21 PM)alexkidd Wrote: OK, recompiled and tested from SSH, seems to be working with uncompressed .gba roms

Tested, it works Smile Thank you!
How does the build differ from the binary we get by doing "update from source" in setup script? Any patches?
I tried from libretro github, i think the update script use retropie fork
AFAIK no, from what I see from build log:

git clone --depth 1 "" "/home/pi/RetroPie-Setup/tmp/build/lr-mgba"

I confirm that your build works OK, the one I'm doing from setup script is not.
strange, i thought it was retropie's... I just ran:

git clone
make -j2 -f Makefile.libretro

i wonder if the --depth 1 makes any difference
Cloned repo with --depth 1 and got working binary in the end.

Here's what script does:

function build_lr-mgba() {
   make -f Makefile.libretro clean
   if isPlatform "neon"; then
       make -f Makefile.libretro HAVE_NEON=1
       make -f Makefile.libretro

This does not differ from what I'm doing manually (HAVE_NEON is not used anyway).

Okay, found something. Script adds extra CFLAGS (at the beginning):

-O2 -march=armv7-a -mfpu=neon-vfpv4 -mfloat-abi=hard -ftree-vectorize -funsafe-math-optimizations -pipe

-O2 is later overwritten but others are not. All except -pipe are added in scriptmodules/

function platform_armv7-mali() {
    __default_cflags="-O2 -march=armv7-a -mfpu=neon-vfpv4 -mfloat-abi=hard -ftree-vectorize -funsafe-math-optimizations"
    __platform_flags="arm armv7 neon mali"

Build produces working binary if I remove all CFLAGS changes (left __default_cflags=""). Will try to find these that break things but not today, now I'm going to celebrate New Year's Eve. Big Grin

It's -mfpu=neon-vfpv4 that breaks things on OPi PC. To fix "Update from source" feature in RetroPie-Setup remove this value from /home/pi/RetroPie-Setup/scriptmodules/ line 261 so it reads:

__default_cflags="-O2 -march=armv7-a -mfloat-abi=hard -ftree-vectorize -funsafe-math-optimizations"

After that change build produces working binary lr-mgba core.

Happy New Year!

Possibly Related Threads...
Thread Author Replies Views Last Post
  dosbox segfaults in 3.0.1 greenais 2 44 10-18-2017, 10:39 PM
Last Post: greenais

Forum Jump:

Users browsing this thread: 1 Guest(s)