Skip to content

Commit 433d898

Browse files
committed
default to not use vendored tinyxml2 in a ros environment
1 parent 36d13ed commit 433d898

File tree

2 files changed

+5
-1
lines changed

2 files changed

+5
-1
lines changed

CMakeLists.txt

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,7 @@ option(USE_VENDORED_FLATBUFFERS "Use the bundled version of flatbuffers" ON)
2828
option(USE_VENDORED_LEXY "Use the bundled version of lexy" ON)
2929
option(USE_VENDORED_MINICORO "Use the bundled version of minicoro" ON)
3030
option(USE_VENDORED_MINITRACE "Use the bundled version of minitrace" ON)
31-
option(USE_VENDORED_TINYXML2 "Use the bundled version of tinyxml2" ON)
31+
# Usage of TINYXML2 sits with the ROS2 lookup
3232

3333
set(BTCPP_LIB_DESTINATION lib)
3434
set(BTCPP_INCLUDE_DESTINATION include)
@@ -84,6 +84,7 @@ if(POLICY CMP0057)
8484
cmake_policy(SET CMP0057 NEW)
8585
endif()
8686

87+
set(_default_use_vendored_tiny_xml ON)
8788
find_package(ament_cmake QUIET)
8889

8990
if ( ament_cmake_FOUND )
@@ -93,12 +94,14 @@ if ( ament_cmake_FOUND )
9394
message(STATUS "BehaviorTree is being built using AMENT.")
9495
message(STATUS "------------------------------------------")
9596
include(cmake/ament_build.cmake)
97+
set(_default_use_vendored_tiny_xml OFF)
9698
else()
9799
message(STATUS "------------------------------------------")
98100
message(STATUS "BehaviorTree is being built without AMENT.")
99101
message(STATUS "------------------------------------------")
100102
include(cmake/conan_build.cmake)
101103
endif()
104+
option(USE_VENDORED_TINYXML2 "Use the bundled version of tinyxml2" ${_default_use_vendored_tiny_xml})
102105

103106
#############################################################
104107
# Handle dependencies

package.xml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -22,6 +22,7 @@
2222

2323
<depend>libsqlite3-dev</depend>
2424
<depend>libzmq3-dev</depend>
25+
<depend>tinyxml2</depend>
2526

2627
<test_depend >ament_cmake_gtest</test_depend>
2728

0 commit comments

Comments
 (0)