BUILD_TESTING is shared by the whole CMake tree: any package that calls
include(CTest) turns it on and would build these tests too. The own
option defaults to OFF in both build modes.
GTest is only used by the test executables, which the robot deployment build
does not produce. Requiring it at the top of the file made cmake fail to
configure on a machine without GTest installed even with the tests off.
The test target listed Boost::system and Boost::thread while this package
never calls find_package(Boost). The imported targets only existed because
another subdirectory happened to be configured first, so CMake passed the
literal strings through and the link failed with "cannot find -lBoost::system"
whenever that ordering did not hold.
The test does not use Boost itself; whatever it needs arrives through the
library it links. Dropping the two entries removes the ordering dependency.
* Stop using python_cmake_module.
We really don't need it anymore, and can just use the
builtin find_package(Python3).
* Add in missing ament_cmake_python dependency.
Signed-off-by: Chris Lalancette <clalancette@gmail.com>
This allows us to hide more of the libraries from downstream
consumers.
While we are in here, do slight cleanups so it is more clear
which libraries are depended on.
Signed-off-by: Chris Lalancette <clalancette@gmail.com>
The main reason to do this is so that we can compile laser_geometry
with the clang static analyzer. As of clang++-14 (what is in
Ubuntu 22.04), the default still seems to be C++14, so we need
to specify C++17 so that new things in the rclcpp headers work
properly.
Further, due to reasons I don't fully understand, I needed to
set CMAKE_CXX_STANDARD_REQUIRED in order for clang to really use
that version. So set this as well.
Signed-off-by: Chris Lalancette <clalancette@openrobotics.org>