[CMake?] libdivide and libgme cause compile warnings
libdivide and libgme cause warnings when compiling (at least when using CMake), preventing the game from being compiled with SRB2_CONFIG_ERRORMODE
. This wasn't an issue for me (with MinGW-w64's mingw32-make) prior to the CMakening.
The two/three types of warnings shown are...
D:/SteamLibrary/NonSteam/Games/Sonic/Sonic Robo Blast 2/Source/build/_deps/libgme-src/gme/Hes_Cpu.cpp: In member function 'bool Hes_Cpu::run(hes_time_t)':
D:/SteamLibrary/NonSteam/Games/Sonic/Sonic Robo Blast 2/Source/build/_deps/libgme-src/gme/Hes_Cpu.cpp:878:22: warning: conversion from 'unsigned int' to 'uint_fast16_t' {aka 'short unsigned int'} changes value from '4294967295' to '65535' [-Woverflow]
878 | nz = (unsigned) -1;
| ^~~~~~~~~~~~~
[...]
D:/SteamLibrary/NonSteam/Games/Sonic/Sonic Robo Blast 2/Source/src/libdivide.h: In function 'libdivide_u32_gen':
D:/SteamLibrary/NonSteam/Games/Sonic/Sonic Robo Blast 2/Source/src/libdivide.h:637:24: warning: function returns an aggregate [-Waggregate-return]
637 | struct libdivide_u32_t libdivide_u32_gen(uint32_t d) {
| ^~~~~~~~~~~~~~~~~
D:/SteamLibrary/NonSteam/Games/Sonic/Sonic Robo Blast 2/Source/src/libdivide.h:638:12: warning: function call has aggregate value [-Waggregate-return]
638 | return libdivide_internal_u32_gen(d, 0);
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
[...]