Merge pull request #111 from waywardmonkeys/fix-tmpnam-warning

Enable LUA_USE_POSIX, fix tmpnam warning on macOS.
This commit is contained in:
rxi 2020-05-22 18:59:42 +01:00 committed by GitHub
commit 71fb50ece0
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -1,13 +1,13 @@
#!/bin/bash
cflags="-Wall -O3 -g -std=gnu11 -Isrc -DLUA_USE_POPEN"
cflags="-Wall -O3 -g -std=gnu11 -Isrc"
lflags="-lSDL2 -lm"
if [[ $* == *windows* ]]; then
platform="windows"
outfile="lite.exe"
compiler="x86_64-w64-mingw32-gcc"
cflags="$cflags -Iwinlib/SDL2-2.0.10/x86_64-w64-mingw32/include"
cflags="$cflags -DLUA_USE_POPEN -Iwinlib/SDL2-2.0.10/x86_64-w64-mingw32/include"
lflags="$lflags -Lwinlib/SDL2-2.0.10/x86_64-w64-mingw32/lib"
lflags="-lmingw32 -lSDL2main $lflags -mwindows -o $outfile res.res"
x86_64-w64-mingw32-windres res.rc -O coff -o res.res
@ -15,6 +15,7 @@ else
platform="unix"
outfile="lite"
compiler="gcc"
cflags="$cflags -DLUA_USE_POSIX"
lflags="$lflags -o $outfile"
fi