Skip to content

Commit

Permalink
enable using externally-built mrpt-libs
Browse files Browse the repository at this point in the history
  • Loading branch information
jlblancoc committed Jul 26, 2024
1 parent 07939a9 commit e18b25d
Showing 1 changed file with 8 additions and 2 deletions.
10 changes: 8 additions & 2 deletions cmakemodules/DeclareMRPTLib.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -314,8 +314,14 @@ macro(internal_define_mrpt_lib name headers_only )
# Now, check mrpt-* deps only:
# Check if all dependencies are to be build:
if ("${BUILD_mrpt-${DEP_MRPT_NAME}}" STREQUAL "OFF")
set(AUX_ALL_DEPS_BUILD 0)
message(STATUS "*Warning*: Lib mrpt-${name} cannot be built because dependency mrpt-${DEP_MRPT_NAME} has been disabled!")
# Attempt at using system version?
find_package(mrpt-${DEP_MRPT_NAME})
if (NOT TARGET mrpt::${DEP_MRPT_NAME})
set(AUX_ALL_DEPS_BUILD 0)
message(STATUS "*Warning*: Lib mrpt-${name} cannot be built because dependency mrpt-${DEP_MRPT_NAME} has been disabled!")
else()
message(STATUS "*Warning*: Lib mrpt-${name} is using system depency: mrpt-${DEP_MRPT_NAME}")
endif()
endif ()
endif ()
endforeach()
Expand Down

0 comments on commit e18b25d

Please sign in to comment.