At some point snprintf(3) prototype became guarded off in stdio.h.
Defining _C99_SOURCE makes it visible.
On legacy Darwin, such a guard was not present so the definition
has no impact on the build, but on "modern" macos it has the desired
effect.
Build tested on OS X 10.4 and macos 10.15.
... | ... |
@@ -79,7 +79,7 @@ MSYS_NT*|MINGW*) # MSYS2 on Windows |
79 | 79 |
fi |
80 | 80 |
;; |
81 | 81 |
Darwin) # macOS |
82 |
- CFLAGS="${CFLAGS} -Wno-typedef-redefinition" |
|
82 |
+ CFLAGS="${CFLAGS} -Wno-typedef-redefinition -D_C99_SOURCE" |
|
83 | 83 |
UXNEMU_LDFLAGS="$(brew --prefix)/lib/libSDL2.a $(sdl2-config --cflags --static-libs | sed -e 's/-lSDL2 //')" |
84 | 84 |
;; |
85 | 85 |
Linux|*) |