diff --git a/core/CMakeLists.txt b/core/CMakeLists.txt index a9bcec9..b902283 100644 --- a/core/CMakeLists.txt +++ b/core/CMakeLists.txt @@ -14,6 +14,7 @@ find_package(ASSIMP REQUIRED) if (LUA_ENABLED) ## Find Lua find_package(Lua REQUIRED) +include_directories(${LUA_INCLUDE_DIR}) endif () add_library(couchlib STATIC) @@ -94,7 +95,6 @@ target_link_libraries(couchlib OpenGL::GL) target_link_libraries(couchlib GLEW::GLEW) if (LUA_ENABLED) target_link_libraries(couchlib_luascripting ${LUA_LIBRARIES}) - target_include_directories(couchlib_luascripting PRIVATE "${LUA_INCLUDE_DIR}") endif () target_link_libraries(couchlib ${BULLET_LIBRARIES}) target_link_libraries(couchlib ${ASSIMP_LIBRARY}) diff --git a/scripting/CMakeLists.txt b/scripting/CMakeLists.txt index 53bce77..98e1b67 100644 --- a/scripting/CMakeLists.txt +++ b/scripting/CMakeLists.txt @@ -12,9 +12,7 @@ if (LUA_ENABLED) LANGUAGE lua SOURCES couch.i lua/helpers.i) - target_include_directories(couchlua PRIVATE - "${PROJECT_SOURCE_DIR}/core" - "${LUA_INCLUDE_DIR}") + target_include_directories(couchlua PRIVATE "${PROJECT_SOURCE_DIR}/core") swig_link_libraries(couchlua PRIVATE