diff options
author | est31 <MTest31@outlook.com> | 2015-02-12 16:13:14 +1000 |
---|---|---|
committer | Craig Robbins <kde.psych@gmail.com> | 2015-02-12 16:14:12 +1000 |
commit | b2f3ffe3081a3cd49c0536257aab86b82b022cae (patch) | |
tree | 17091dcd9d0941c9fb94cc93c4f26abc39f19da8 | |
parent | 66efaaa983cde27e0ad2f9cc142950a62c868765 (diff) | |
download | minetest-b2f3ffe3081a3cd49c0536257aab86b82b022cae.tar.gz minetest-b2f3ffe3081a3cd49c0536257aab86b82b022cae.tar.bz2 minetest-b2f3ffe3081a3cd49c0536257aab86b82b022cae.zip |
Enable LUA_USE_POSIX if possible in bundled Lua
Fixes warning:
src/lua/src/loslib.c:60: Warning: the use of `tmpnam' is dangerous, better use `mkstemp'
-rw-r--r-- | src/lua/CMakeLists.txt | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/src/lua/CMakeLists.txt b/src/lua/CMakeLists.txt index 36e271889..4bfe318ee 100644 --- a/src/lua/CMakeLists.txt +++ b/src/lua/CMakeLists.txt @@ -47,10 +47,6 @@ else() endif() mark_as_advanced(LUA_USE_DLOPEN) -if(DEFAULT_POSIX) -else() -endif() - if(DEFAULT_ANSI) option(LUA_ANSI "Disable non-ansi features." ON) else() @@ -87,6 +83,10 @@ if(LUA_USE_DLOPEN) endif(NOT APPLE) endif(LUA_USE_DLOPEN) +if(DEFAULT_POSIX) + set(COMMON_CFLAGS "${COMMON_CFLAGS} -DLUA_USE_POSIX") +endif(DEFAULT_POSIX) + if(LUA_ANSI) set(COMMON_CFLAGS "${COMMON_CFLAGS} -DLUA_ANSI") endif(LUA_ANSI) |