drhelius / Gearsystem

Sega Master System / Game Gear / SG-1000 emulator for macOS, Windows, Linux, BSD and RetroArch.
https://x.com/drhelius
GNU General Public License v3.0
247 stars 45 forks source link

Releases from 3.4.0 onward can't run on Linux Mint 20 (and Ubuntu 20.04) #85

Closed sverx closed 4 months ago

sverx commented 6 months ago

Hello! Somebody suggested me to try this emulator, and I'm doing it.

Unfortunately the last release I can run on my Linux Mint 20 is the 3.3.0 release. After that release I just get this output, likely because your build environment is using a more recent GLIBC version.

~/GearSystem/Gearsystem-3.4.0-Linux$ ./gearsystem 
./gearsystem: /lib/x86_64-linux-gnu/libstdc++.so.6: version `GLIBCXX_3.4.29' not found (required by ./gearsystem)
./gearsystem: /lib/x86_64-linux-gnu/libc.so.6: version `GLIBC_2.32' not found (required by ./gearsystem)
./gearsystem: /lib/x86_64-linux-gnu/libc.so.6: version `GLIBC_2.33' not found (required by ./gearsystem)

Note that Linux Mint 20 is based on Ubuntu 20.04, so they both will be supported until mid-2025. You might want to build your release on an Ubuntu 20.04 box to make sure more people do not need to resort to compile from the sources themselves.

drhelius commented 6 months ago

Good to know, thanks.

sverx commented 6 months ago

Also, but unrelated to this issue, the person that suggested me to try this emulator just told me 3.4.2 crashes on my latest SMS Test Suite v0.35.

128: --> ** Output to memory control port $3E: E0 129: Port 3E: BIOS

Thread 1 "gearsystem" received signal SIGSEGV, Segmentation fault. 0x00005555556767d1 in BootromMemoryRule::PerformRead (this=0x5555557ae360, address=256) at ../../src/BootromMemoryRule.cpp:38 38 return m_pBootrom[address];`

drhelius commented 6 months ago

I was able to reproduce the issue. The crash is because the program is enabling BIOS via port 0x3E but you don't have any BIOS loaded. You must load a BIOS before, the emulator does not include any BIOS in it. With a loaded BIOS it runs normally.

sverx commented 6 months ago

I thought that would be the reason. In a real world scenario I suspect reading the BIOS when no ROM chip is there, the code would probably just read 0xFF all over the place, or zeroes. But whatever the emulator returns in this extreme case, it doesn't really matter - as long as it doesn't crash :wink:

drhelius commented 6 months ago

Yes, reading 0xFF can be an option. I'll probably fix it to avoid crashing.

nixon87 commented 6 months ago

Hello, I was the person that suggested sverx your emulator (My github account wasn't active at that time) :) Thank you for gearsystem, and thank you for the fast response, I recompiled today and Gearsystem doesn't crash anymore with sms test suite v0.35 without a bios.

drhelius commented 4 months ago

Fixed on the new GH Actions workflow. It now builds for Ubuntu 20.04 too and it will be included in the next release. i.e.: https://github.com/drhelius/Gearsystem/actions/runs/8047742265