Fix some issues with the build system

There is still an issue: `aguya.cpp:51:16: error: ‘kaguya’ has not been declared`.

Signed-off-by: Gaël Écorchard <gael@km-robotics.cz>
This commit is contained in:
Gaël Écorchard 2023-10-12 12:59:24 +02:00
parent 9c882a28fd
commit 3be33dc8c3
2 changed files with 6 additions and 3 deletions

View File

@ -45,6 +45,7 @@ ExternalProject_Add(KAGUYA_BUILD_SOURCE
GIT_SHALLOW TRUE GIT_SHALLOW TRUE
GIT_SUBMODULES "" GIT_SUBMODULES ""
GIT_REPOSITORY https://github.com/satoren/kaguya.git GIT_REPOSITORY https://github.com/satoren/kaguya.git
GIT_TAG main
PREFIX ${kaguya_build_toplevel} PREFIX ${kaguya_build_toplevel}
SOURCE_DIR ${kaguya_build_toplevel} SOURCE_DIR ${kaguya_build_toplevel}
DOWNLOAD_DIR ${kaguya_build_toplevel} DOWNLOAD_DIR ${kaguya_build_toplevel}

View File

@ -199,7 +199,7 @@ extern \"C\" {
file(TO_NATIVE_PATH "${LUA_VANILLA_SOURCE_LUA_HPP}" LUA_VANILLA_SOURCE_LUA_HPP) file(TO_NATIVE_PATH "${LUA_VANILLA_SOURCE_LUA_HPP}" LUA_VANILLA_SOURCE_LUA_HPP)
endif() endif()
set(LUA_VANILLA_INCLUDE_DIRS ${lua-vanilla_SOURCE_DIR}/include) set(LUA_VANILLA_INCLUDE_DIRS ${lua-vanilla_SOURCE_DIR}/src)
endif() endif()
# # Target names # # Target names
@ -251,7 +251,9 @@ else()
endif() endif()
target_compile_options(${liblua} target_compile_options(${liblua}
PRIVATE ${LUA_VANILLA_LUALIB_COMPILER_OPTIONS}) PRIVATE ${LUA_VANILLA_LUALIB_COMPILER_OPTIONS})
add_dependencies(${liblua} LUA_VANILLA) if (LUA_LOCAL_DIR)
add_dependencies(${liblua} LUA_VANILLA)
endif()
target_link_libraries(${liblua} PRIVATE ${CMAKE_DL_LIBS}) target_link_libraries(${liblua} PRIVATE ${CMAKE_DL_LIBS})
if (UNIX) if (UNIX)
target_link_libraries(${liblua} PRIVATE m) target_link_libraries(${liblua} PRIVATE m)