Browse Source

Fix gkd350h build

Works around a GCC bug on some platforms:
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=97044
pull/2009/head
Gleb Mazovetskiy 5 years ago committed by Anders Jenbo
parent
commit
2f3fa76320
  1. 4
      CMake/gkd350h_defs.cmake
  2. 7
      Source/engine.h

4
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)

7
Source/engine.h

@ -21,6 +21,13 @@
#include <tuple>
#include <utility>
// 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 <cinttypes>
#include <SDL.h>
#ifdef USE_SDL1

Loading…
Cancel
Save