Stephane-D / SGDK

SGDK - A free and open development kit for the Sega Mega Drive
https://www.patreon.com/SGDK
MIT License
1.7k stars 179 forks source link

Improved support for newer Linux based GCC tools #308

Closed iratahack closed 5 months ago

iratahack commented 5 months ago
  1. makelib.gen: Added -ffat-lto-objects to library compile options. Without this, newer linkers strip vital symbols which cause the final link to fail.
  2. makefile.gen: Added -flto to final link stage. Also added -m68000 as some newer linkers generate non-68k code without this which cause runtime exceptions.
  3. common.mk: Changed PREFIX setting from := to ?= so it can be overridden from an environment variable.
  4. Fixed compiler warnings in string.c. Double use of const.

Changes have been confirmed to work in the default Windows environment.