summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
Diffstat (limited to '')
-rw-r--r--lib/lua/CMakeLists.txt9
1 files changed, 9 insertions, 0 deletions
diff --git a/lib/lua/CMakeLists.txt b/lib/lua/CMakeLists.txt
index b4b5b5f1d..ff5dc927c 100644
--- a/lib/lua/CMakeLists.txt
+++ b/lib/lua/CMakeLists.txt
@@ -25,6 +25,15 @@ else()
add_library(lua ${SOURCE})
endif()
+# Tell Lua what dynamic loader to use (for LuaRocks):
+if (UNIX)
+ if (APPLE)
+ add_definitions(-DLUA_USE_MACOSX)
+ else()
+ add_definitions(-DLUA_USE_LINUX)
+ endif ()
+endif()
+
if (UNIX)
target_link_libraries(lua m ${DYNAMIC_LOADER})
endif()