Skip to content
Open
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
53 changes: 53 additions & 0 deletions shared/patch/ros2-beluga.patch
Original file line number Diff line number Diff line change
@@ -0,0 +1,53 @@
diff --git a/CMakeLists.txt b/CMakeLists.txt
index 5c08a64..b94a7f1 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -94,7 +94,7 @@ target_sources(clang_tidy_findable PRIVATE src/clang_tidy_findable.cpp)
target_link_libraries(clang_tidy_findable PRIVATE ${PROJECT_NAME}
beluga_compile_options)

-option(BUILD_TESTING "Build the testing tree." ON)
+option(BUILD_TESTING "Build the testing tree." OFF)
if(BUILD_TESTING)
message(STATUS "Build testing enabled.")
enable_testing()
diff --git a/include/beluga/policies/on_motion.hpp b/include/beluga/policies/on_motion.hpp
index 9d7ad43..5cb6d95 100644
--- a/include/beluga/policies/on_motion.hpp
+++ b/include/beluga/policies/on_motion.hpp
@@ -15,7 +15,7 @@
#ifndef BELUGA_POLICIES_ON_MOTION_HPP
#define BELUGA_POLICIES_ON_MOTION_HPP

-#include <Eigen/src/Geometry/AngleAxis.h>
+#include <Eigen/Geometry>
#include <beluga/policies/policy.hpp>
#include <sophus/se2.hpp>
#include <sophus/se3.hpp>
@@ -119,12 +119,13 @@ struct on_motion_policy : public on_motion_policy_base<Pose> {

/// Return true if motion has been detected.
constexpr bool operator()(const Pose& pose) {
- if (!latest_pose_) {
+ if (!has_latest_pose_) {
latest_pose_ = pose;
+ has_latest_pose_ = true;
return true;
}

- const bool moved = (*this)(*latest_pose_, pose);
+ const bool moved = (*this)(latest_pose_, pose);
if (moved) {
latest_pose_ = pose;
}
@@ -133,7 +134,9 @@ struct on_motion_policy : public on_motion_policy_base<Pose> {
}

private:
- std::optional<Pose> latest_pose_; ///< The latest pose for motion comparison.
+ // a flag instead of std::optional<Pose>: GCC 15 fails to instantiate std::optional<Sophus::SE3>
+ bool has_latest_pose_{false}; ///< Whether latest_pose_ holds a pose.
+ Pose latest_pose_{}; ///< The latest pose for motion comparison.
};

/// Implementation detail for the on_motion_fn object.
2 changes: 2 additions & 0 deletions shared/vinca.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -395,6 +395,8 @@ packages_select_by_deps:
- apex_containers
- apriltag_ros # These packages are currently only build on Linux,; as trying to build them in the past on macos or Windows resulted in errors
- avt_vimba_camera # ships some Linux .so in the repo, so it only supports linux
- beluga_amcl # macOS: libc++ lacks std::execution::sequenced_policy; requested in https://github.com/RoboStack/ros-jazzy/pull/298
- beluga_ros # macOS: libc++ lacks std::execution::sequenced_policy; requested in https://github.com/RoboStack/ros-jazzy/pull/298
Comment on lines +398 to +399

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
- beluga_amcl # macOS: libc++ lacks std::execution::sequenced_policy; requested in https://github.com/RoboStack/ros-jazzy/pull/298
- beluga_ros # macOS: libc++ lacks std::execution::sequenced_policy; requested in https://github.com/RoboStack/ros-jazzy/pull/298
- beluga_amcl # macOS: libc++ lacks std::execution::sequenced_policy
- beluga_ros # macOS: libc++ lacks std::execution::sequenced_policy

I don't think this is relevant information. And if one really wants to know, it's one search away..

- camera_ros # Depends on libcamera that is only available on linux; Depends on libcamera, only available on linux
- can_dbc_parser
- easynav
Expand Down