all repos — mgba @ 73c38b95b6be95ab9c58369fe7186fc197e1255e

mGBA Game Boy Advance Emulator

All: Correct more format strings on Windows (fixes #1817)
Vicki Pfau vi@endrift.com
Sat, 11 Jul 2020 15:34:45 -0700
commit

73c38b95b6be95ab9c58369fe7186fc197e1255e

parent

145a31868a21454ab91e2070ed6103bde333bbc9

3 files changed, 9 insertions(+), 0 deletions(-)

jump to
M CHANGESCHANGES

@@ -29,6 +29,7 @@ - SM83: Emulate HALT bug

Other fixes: - All: Improve export headers (fixes mgba.io/i/1738) - All: Correct format strings for some numbers on Windows (fixes mgba.io/i/1794) + - All: Correct more format strings on Windows (fixes mgba.io/i/1817) - Core: Ensure ELF regions can be written before trying - Debugger: Don't skip undefined instructions when debugger attached - FFmpeg: Fix some small memory leaks
M CMakeLists.txtCMakeLists.txt

@@ -20,6 +20,10 @@ elseif(CMAKE_C_COMPILER_ID STREQUAL "GNU" AND CMAKE_C_COMPILER_VERSION VERSION_LESS "4.3")

set(CMAKE_C_EXTENSIONS ON) endif() set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -Wall -Wextra -Wno-missing-field-initializers") + if(WIN32) + # mingw32 likes to complain about using the "wrong" format strings despite them actually working + set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -Wno-format") + endif() else() set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -D_CRT_SECURE_NO_WARNINGS /wd4003 /wd4244 /wd4146") endif()
M include/mgba-util/common.hinclude/mgba-util/common.h

@@ -14,6 +14,10 @@ #define CXX_GUARD_START

#define CXX_GUARD_END #endif +#ifdef __MINGW32__ +#define __USE_MINGW_ANSI_STDIO 1 +#endif + CXX_GUARD_START #include <ctype.h>