2023-03-12 15:55:17 +00:00
|
|
|
cmake_minimum_required(VERSION 3.1)
|
|
|
|
project(lua-config-package-test C)
|
|
|
|
|
|
|
|
find_package(Lua REQUIRED CONFIG)
|
|
|
|
|
|
|
|
add_executable(lua-config-package-build-test-using-static-target "./lua-config-package-build-test.c")
|
|
|
|
target_link_libraries(lua-config-package-build-test-using-static-target Lua::lua_static)
|
|
|
|
|
|
|
|
add_executable(lua-config-package-build-test-using-shared-target "./lua-config-package-build-test.c")
|
2023-03-12 17:25:09 +00:00
|
|
|
target_link_libraries(lua-config-package-build-test-using-shared-target Lua::lua_shared)
|
2023-03-12 15:55:17 +00:00
|
|
|
|
|
|
|
add_executable(lua-config-package-build-test-using-variables "./lua-config-package-build-test.c")
|
|
|
|
target_link_libraries(lua-config-package-build-test-using-variables ${LUA_LIBRARIES})
|
|
|
|
|
2023-03-13 05:29:06 +00:00
|
|
|
add_library(lua-lib-module-compatible-mode UNKNOWN IMPORTED ${LUA_LIBRARY})
|
|
|
|
set_target_properties(lua-lib-module-compatible-mode PROPERTIES
|
|
|
|
INTERFACE_INCLUDE_DIRECTORIES ${LUA_INCLUDE_DIR}
|
|
|
|
IMPORTED_LOCATION ${LUA_LIBRARY})
|
|
|
|
|
|
|
|
add_executable(lua-config-package-build-test-using-module-compatible-mode "./lua-config-package-build-test.c")
|
|
|
|
target_link_libraries(lua-config-package-build-test-using-module-compatible-mode lua-lib-module-compatible-mode)
|