Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

link against tinyxml2 correctly #190

Merged
merged 3 commits into from
May 20, 2020
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion pluginlib/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ add_library(${PROJECT_NAME} INTERFACE)
target_include_directories(${PROJECT_NAME} INTERFACE
"$<INSTALL_INTERFACE:include>")
ament_target_dependencies(${PROJECT_NAME} INTERFACE
ament_index_cpp class_loader rcutils rcpputils tinyxml2_vendor TinyXML2)
ament_index_cpp class_loader rcutils rcpputils TinyXML2)
dirk-thomas marked this conversation as resolved.
Show resolved Hide resolved
ament_export_dependencies(ament_index_cpp class_loader rcutils rcpputils tinyxml2_vendor TinyXML2)
ament_export_include_directories(include)
ament_export_targets(${PROJECT_NAME})
Expand Down
11 changes: 0 additions & 11 deletions pluginlib/pluginlib-extras.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -40,14 +40,3 @@ if(UNIX AND NOT APPLE)
# ament_export_libraries() because it is not absolute and cannot be found with find_library
list(APPEND pluginlib_LIBRARIES ${FILESYSTEM_LIB})
endif()

find_package(tinyxml2_vendor REQUIRED)
find_package(TinyXML2 REQUIRED)
list(APPEND pluginlib_LIBRARIES ${TinyXML2_LIBRARIES})

add_library(tinyxml2_vendor INTERFACE IMPORTED)
target_include_directories(tinyxml2_vendor INTERFACE
${TinyXML2_INCLUDE_DIRS})
target_link_libraries(tinyxml2_vendor INTERFACE
${TinyXML2_LIBRARIES})
list(APPEND pluginlib_TARGETS tinyxml2_vendor)