From 7f0255f13c55034ec14ea055d04d947a0c42a2c6 Mon Sep 17 00:00:00 2001 From: Piotr Kubaj Date: Mon, 15 Feb 2021 16:44:52 +0000 Subject: [PATCH] games/libretro-bluemsx: fix build on powerpc64le Src/SoundChips/OpenMsxYM2413.cpp:331:10: error: constant expression evaluates to -3 which cannot be narrowed to type 'char' [-Wc++11-narrowing] 7, 3, 0,-3,-7,-3, 0, 3, Since it should also fix build on other architectures with unsigned char, unbreak on aarch64 and riscv64 (untested). --- games/libretro-bluemsx/Makefile | 3 --- .../files/patch-Src_SoundChips_OpenMsxYM2413.cpp | 11 +++++++++++ 2 files changed, 11 insertions(+), 3 deletions(-) create mode 100644 games/libretro-bluemsx/files/patch-Src_SoundChips_OpenMsxYM2413.cpp diff --git a/games/libretro-bluemsx/Makefile b/games/libretro-bluemsx/Makefile index 0352b73386cd..7c86046a5585 100644 --- a/games/libretro-bluemsx/Makefile +++ b/games/libretro-bluemsx/Makefile @@ -9,9 +9,6 @@ COMMENT= Port of blueMSX to the libretro API LICENSE= GPLv3 -BROKEN_aarch64= error: constant expression evaluates to -1 which cannot be narrowed to type 'char' [-Wc++11-narrowing] -BROKEN_riscv64= error: constant expression evaluates to -1 which cannot be narrowed to type 'char' [-Wc++11-narrowing] - USES= compiler:c++11-lib gmake USE_LDCONFIG= yes diff --git a/games/libretro-bluemsx/files/patch-Src_SoundChips_OpenMsxYM2413.cpp b/games/libretro-bluemsx/files/patch-Src_SoundChips_OpenMsxYM2413.cpp new file mode 100644 index 000000000000..739a21f79029 --- /dev/null +++ b/games/libretro-bluemsx/files/patch-Src_SoundChips_OpenMsxYM2413.cpp @@ -0,0 +1,11 @@ +--- Src/SoundChips/OpenMsxYM2413.cpp.orig 2021-02-15 16:41:14 UTC ++++ Src/SoundChips/OpenMsxYM2413.cpp +@@ -304,7 +304,7 @@ static const byte lfo_am_table[LFO_AM_TAB_ELEMENTS] = + }; + + // LFO Phase Modulation table (verified on real YM2413) +-static const char lfo_pm_table[8 * 8] = ++static const signed char lfo_pm_table[8 * 8] = + { + // FNUM2/FNUM = 0 00xxxxxx (0x0000) + 0, 0, 0, 0, 0, 0, 0, 0,