Fix build without Lua

This commit is contained in:
Přemysl Eric Janouch 2015-10-01 22:58:18 +02:00
parent d9d9e1f498
commit 9c16e19786
1 changed files with 5 additions and 1 deletions

View File

@ -42,10 +42,14 @@ endif (ncursesw_FOUND)
# FIXME: for "lua" we also need to check that it is < 5.4 # FIXME: for "lua" we also need to check that it is < 5.4
# which doesn't seem to be possible with FindPkgConfig # which doesn't seem to be possible with FindPkgConfig
pkg_search_module (lua REQUIRED lua5.3 lua-5.3 lua>=5.3) pkg_search_module (lua lua5.3 lua-5.3 lua>=5.3)
option (WITH_LUA "Enable experimental support for Lua 5.3 plugins" ${lua_FOUND}) option (WITH_LUA "Enable experimental support for Lua 5.3 plugins" ${lua_FOUND})
if (WITH_LUA) if (WITH_LUA)
if (NOT lua_FOUND)
message (FATAL_ERROR "Lua library not found")
endif (NOT lua_FOUND)
list (APPEND project_libraries ${lua_LIBRARIES}) list (APPEND project_libraries ${lua_LIBRARIES})
include_directories (${lua_INCLUDE_DIRS}) include_directories (${lua_INCLUDE_DIRS})
link_directories (${lua_LIBRARY_DIRS}) link_directories (${lua_LIBRARY_DIRS})