diff --git a/CMake/gkd350h_defs.cmake b/CMake/gkd350h_defs.cmake index 10d2a4c81..0ce689539 100644 --- a/CMake/gkd350h_defs.cmake +++ b/CMake/gkd350h_defs.cmake @@ -1,6 +1,10 @@ set(NONET ON) set(USE_SDL1 ON) +# Do not warn about unknown attributes, such as [[nodiscard]]. +# As this build uses an older compiler, there are lots of them. +set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Wno-attributes") + # GKD350h IPU scaler is broken at the moment set(DEFAULT_WIDTH 320) set(DEFAULT_HEIGHT 240) diff --git a/Source/engine.h b/Source/engine.h index daea2718a..062e74e71 100644 --- a/Source/engine.h +++ b/Source/engine.h @@ -21,6 +21,13 @@ #include #include +// We include `cinttypes` here so that it is included before `inttypes.h` +// to work around a bug in older GCC versions on some platforms, +// where including `inttypes.h` before `cinttypes` leads to missing +// defines for `PRIuMAX` et al. SDL transitively includes `inttypes.h`. +// See https://gcc.gnu.org/bugzilla/show_bug.cgi?id=97044 +#include + #include #ifdef USE_SDL1