Commit f5aee6be authored by Laurent Claustre's avatar Laurent Claustre

Merge branch 'fix-cmake-submodules-sip' into 'master'

Fix SIP_INCLUDE_DIRS variables for submodule build

See merge request !97
parents a574b6c6 4eed5623
Pipeline #6002 passed with stages
in 9 minutes and 49 seconds
......@@ -303,20 +303,21 @@ if(LIMA_ENABLE_PYTHON)
configure_file(sip/limacore.sip.in sip/limacore.sip)
configure_file(sip/lima_init_numpy.cpp.in sip/core/limacore_init_numpy.cpp)
set(SIP_INCLUDE_DIRS
${PROCESSLIB_SIP_INCLUDE_DIRS}
list(APPEND LIMA_SIP_INCLUDE_DIRS
"${CMAKE_CURRENT_BINARY_DIR}/sip"
"${CMAKE_CURRENT_SOURCE_DIR}/common/sip"
"${CMAKE_CURRENT_SOURCE_DIR}/hardware/sip"
"${CMAKE_CURRENT_SOURCE_DIR}/control/sip"
"${CMAKE_CURRENT_SOURCE_DIR}/control/software_operation/sip")
if (LIMA_BUILD_SUBMODULES)
list(APPEND SIP_INCLUDE_DIRS
"${CMAKE_CURRENT_BINARY_DIR}/sip"
# This is required for LimaTools
list(APPEND PROCESSLIB_SIP_INCLUDE_DIRS
"${CMAKE_CURRENT_SOURCE_DIR}/third-party/Processlib/sip"
"${CMAKE_CURRENT_SOURCE_DIR}/third-party/Processlib/tasks/sip")
# This is required for LimaTools
set(LIMA_SIP_INCLUDE_DIRS "${CMAKE_CURRENT_SOURCE_DIR}/sip")
endif()
set(SIP_INCLUDE_DIRS
${LIMA_SIP_INCLUDE_DIRS}
${PROCESSLIB_SIP_INCLUDE_DIRS})
if (NOT LIMA_ENABLE_CONFIG)
set(SIP_DISABLE_FEATURES ${SIP_DISABLE_FEATURES} WITH_CONFIG)
endif()
......
......@@ -93,7 +93,8 @@ function(limatools_run_sip_for_camera camera)
endforeach()
# Uses INCLUDES and IMPORTS
configure_file(${LIMA_SIP_INCLUDE_DIRS}/limamodules.sip.in sip/${MODULE_NAME}.sip)
find_file(module_sip_file NAMES "limamodules.sip.in" PATHS ${LIMA_SIP_INCLUDE_DIRS} NO_DEFAULT_PATH NO_CMAKE_FIND_ROOT_PATH)
configure_file(${module_sip_file} sip/${MODULE_NAME}.sip)
list(APPEND SIP_INCLUDE_DIRS
${LIMA_SIP_INCLUDE_DIRS}
${PROCESSLIB_SIP_INCLUDE_DIRS}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment