Skip to content

Commit

Permalink
fix error with finding jsoncpp lib
Browse files Browse the repository at this point in the history
  • Loading branch information
hsd-dev committed Oct 22, 2023
1 parent 46ca683 commit 4519b35
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion src/pf_driver/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,11 @@ find_package(tf2_ros REQUIRED)
find_package(pf_interfaces REQUIRED)

find_package(Boost REQUIRED COMPONENTS thread system)
find_package(jsoncpp REQUIRED)
if(NOT TARGET JsonCpp::JsonCpp)
find_package(jsoncpp REQUIRED)
elseif(NOT TARGET jsoncpp_lib)
add_library(jsoncpp_lib ALIAS JsonCpp::JsonCpp)
endif()
find_package(yaml-cpp REQUIRED)
get_target_property(jsoncpp_INCLUDE_DIRS jsoncpp_lib INTERFACE_INCLUDE_DIRECTORIES)
find_package(PkgConfig REQUIRED)
Expand Down

0 comments on commit 4519b35

Please sign in to comment.