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

Build Error on foxy ubnto 20.04 #13

Open
MF-Ahmed opened this issue Feb 12, 2023 · 0 comments
Open

Build Error on foxy ubnto 20.04 #13

MF-Ahmed opened this issue Feb 12, 2023 · 0 comments

Comments

@MF-Ahmed
Copy link

Hi I'm getting the following error while building the foxy branch
--- stderr: mppic
In file included from /home/usr/nav2_ws/install/nav2_costmap_2d/include/nav2_costmap_2d/costmap_2d_publisher.hpp:47,
from /home/usr/nav2_ws/install/nav2_costmap_2d/include/nav2_costmap_2d/costmap_2d_ros.hpp:47,
from /home/usr/data/ros2_ws/src/mppic/src/PathHandler.cpp:1:
/home/usr/nav2_ws/install/nav2_costmap_2d/include/nav2_costmap_2d/costmap_2d.hpp: In member function ‘void nav2_costmap_2d::Costmap2D::raytraceLine(ActionType, unsigned int, unsigned int, unsigned int, unsigned int, unsigned int)’:
/home/usr/nav2_ws/install/nav2_costmap_2d/include/nav2_costmap_2d/costmap_2d.hpp:415:38: error: use of old-style cast to ‘unsigned int’ [-Werror=old-style-cast]
415 | (unsigned int)(scale * abs_dx));
| ^
/home/usr/nav2_ws/install/nav2_costmap_2d/include/nav2_costmap_2d/costmap_2d.hpp:423:36: error: use of old-style cast to ‘unsigned int’ [-Werror=old-style-cast]
423 | (unsigned int)(scale * abs_dy));
| ^
/home/usr/nav2_ws/install/nav2_costmap_2d/include/nav2_costmap_2d/costmap_2d.hpp: In member function ‘void nav2_costmap_2d::Costmap2D::bresenham2D(ActionType, unsigned int, unsigned int, int, int, int, unsigned int, unsigned int)’:
/home/usr/nav2_ws/install/nav2_costmap_2d/include/nav2_costmap_2d/costmap_2d.hpp:442:25: error: use of old-style cast to ‘unsigned int’ [-Werror=old-style-cast]
442 | if ((unsigned int)error_b >= abs_da) {
| ^~~~~~~
In file included from /home/usr/nav2_ws/install/nav2_costmap_2d/include/nav2_costmap_2d/costmap_2d_publisher.hpp:47,
from /home/usr/nav2_ws/install/nav2_costmap_2d/include/nav2_costmap_2d/costmap_2d_ros.hpp:47,
from /home/usr/nav2_ws/install/nav2_core/include/nav2_core/controller.hpp:42,
from /home/usr/data/ros2_ws/src/mppic/include/mppi/Controller.hpp:5,
from /home/usr/data/ros2_ws/src/mppic/src/Controller.cpp:1:
/home/usr/nav2_ws/install/nav2_costmap_2d/include/nav2_costmap_2d/costmap_2d.hpp: In member function ‘void nav2_costmap_2d::Costmap2D::raytraceLine(ActionType, unsigned int, unsigned int, unsigned int, unsigned int, unsigned int)’:
/home/usr/nav2_ws/install/nav2_costmap_2d/include/nav2_costmap_2d/costmap_2d.hpp:415:38: error: use of old-style cast to ‘unsigned int’ [-Werror=old-style-cast]
415 | (unsigned int)(scale * abs_dx));
| ^
/home/usr/nav2_ws/install/nav2_costmap_2d/include/nav2_costmap_2d/costmap_2d.hpp:423:36: error: use of old-style cast to ‘unsigned int’ [-Werror=old-style-cast]
423 | (unsigned int)(scale * abs_dy));
| ^
/home/usr/nav2_ws/install/nav2_costmap_2d/include/nav2_costmap_2d/costmap_2d.hpp: In member function ‘void nav2_costmap_2d::Costmap2D::bresenham2D(ActionType, unsigned int, unsigned int, int, int, int, unsigned int, unsigned int)’:
/home/usr/nav2_ws/install/nav2_costmap_2d/include/nav2_costmap_2d/costmap_2d.hpp:442:25: error: use of old-style cast to ‘unsigned int’ [-Werror=old-style-cast]
442 | if ((unsigned int)error_b >= abs_da) {
| ^~~~~~~
In file included from /home/usr/nav2_ws/install/nav2_costmap_2d/include/nav2_costmap_2d/costmap_2d_publisher.hpp:53,
from /home/usr/nav2_ws/install/nav2_costmap_2d/include/nav2_costmap_2d/costmap_2d_ros.hpp:47,
from /home/usr/data/ros2_ws/src/mppic/src/PathHandler.cpp:1:
/home/usr/nav2_ws/install/nav2_util/include/nav2_util/lifecycle_node.hpp: In member function ‘void nav2_util::LifecycleNode::add_parameter(const string&, const rclcpp::ParameterValue&, nav2_util::LifecycleNode::integer_range, const string&, const string&, bool)’:
/home/usr/nav2_ws/install/nav2_util/include/nav2_util/lifecycle_node.hpp:113:50: error: conversion to ‘rcl_interfaces::msg::IntegerRange_<std::allocator >::step_type’ {aka ‘long unsigned int’} from ‘int’ may change the sign of the result [-Werror=sign-conversion]
113 | descriptor.integer_range[0].step = int_range.step;
| ~~~~~~~~~~^~~~
In file included from /home/usr/nav2_ws/install/nav2_costmap_2d/include/nav2_costmap_2d/costmap_2d_publisher.hpp:53,
from /home/usr/nav2_ws/install/nav2_costmap_2d/include/nav2_costmap_2d/costmap_2d_ros.hpp:47,
from /home/usr/nav2_ws/install/nav2_core/include/nav2_core/controller.hpp:42,
from /home/usr/data/ros2_ws/src/mppic/include/mppi/Controller.hpp:5,
from /home/usr/data/ros2_ws/src/mppic/src/Controller.cpp:1:
/home/usr/nav2_ws/install/nav2_util/include/nav2_util/lifecycle_node.hpp: In member function ‘void nav2_util::LifecycleNode::add_parameter(const string&, const rclcpp::ParameterValue&, nav2_util::LifecycleNode::integer_range, const string&, const string&, bool)’:
/home/usr/nav2_ws/install/nav2_util/include/nav2_util/lifecycle_node.hpp:113:50: error: conversion to ‘rcl_interfaces::msg::IntegerRange
<std::allocator >::step_type’ {aka ‘long unsigned int’} from ‘int’ may change the sign of the result [-Werror=sign-conversion]
113 | descriptor.integer_range[0].step = int_range.step;
| ~~~~~~~~~~^~~~
cc1plus: all warnings being treated as errors
make[2]: *** [CMakeFiles/mppic.dir/build.make:76: CMakeFiles/mppic.dir/src/PathHandler.cpp.o] Error 1
make[2]: *** Waiting for unfinished jobs....
In file included from /home/usr/data/ros2_ws/src/mppic/test/optimizer-test.cpp:7:
/home/usr/nav2_ws/install/nav2_costmap_2d/include/nav2_costmap_2d/costmap_2d.hpp: In member function ‘void nav2_costmap_2d::Costmap2D::raytraceLine(ActionType, unsigned int, unsigned int, unsigned int, unsigned int, unsigned int)’:
/home/usr/nav2_ws/install/nav2_costmap_2d/include/nav2_costmap_2d/costmap_2d.hpp:415:38: error: use of old-style cast to ‘unsigned int’ [-Werror=old-style-cast]
415 | (unsigned int)(scale * abs_dx));
| ^
/home/usr/nav2_ws/install/nav2_costmap_2d/include/nav2_costmap_2d/costmap_2d.hpp:423:36: error: use of old-style cast to ‘unsigned int’ [-Werror=old-style-cast]
423 | (unsigned int)(scale * abs_dy));
| ^
/home/usr/nav2_ws/install/nav2_costmap_2d/include/nav2_costmap_2d/costmap_2d.hpp: In member function ‘void nav2_costmap_2d::Costmap2D::bresenham2D(ActionType, unsigned int, unsigned int, int, int, int, unsigned int, unsigned int)’:
/home/usr/nav2_ws/install/nav2_costmap_2d/include/nav2_costmap_2d/costmap_2d.hpp:442:25: error: use of old-style cast to ‘unsigned int’ [-Werror=old-style-cast]
442 | if ((unsigned int)error_b >= abs_da) {
| ^~~~~~~
In file included from /home/usr/nav2_ws/install/nav2_costmap_2d/include/nav2_costmap_2d/costmap_2d_publisher.hpp:53,
from /home/usr/nav2_ws/install/nav2_costmap_2d/include/nav2_costmap_2d/costmap_2d_ros.hpp:47,
from /home/usr/data/ros2_ws/src/mppic/test/optimizer-test.cpp:8:
/home/usr/nav2_ws/install/nav2_util/include/nav2_util/lifecycle_node.hpp: In member function ‘void nav2_util::LifecycleNode::add_parameter(const string&, const rclcpp::ParameterValue&, nav2_util::LifecycleNode::integer_range, const string&, const string&, bool)’:
/home/usr/nav2_ws/install/nav2_util/include/nav2_util/lifecycle_node.hpp:113:50: error: conversion to ‘rcl_interfaces::msg::IntegerRange
<std::allocator >::_step_type’ {aka ‘long unsigned int’} from ‘int’ may change the sign of the result [-Werror=sign-conversion]
113 | descriptor.integer_range[0].step = int_range.step;
| ~~~~~~~~~~^~~~
cc1plus: all warnings being treated as errors
make[2]: *** [CMakeFiles/mppic.dir/build.make:63: CMakeFiles/mppic.dir/src/Controller.cpp.o] Error 1
make[1]: *** [CMakeFiles/Makefile2:102: CMakeFiles/mppic.dir/all] Error 2
make[1]: *** Waiting for unfinished jobs....
cc1plus: all warnings being treated as errors
make[2]: *** [test/CMakeFiles/optimizer-test.dir/build.make:63: test/CMakeFiles/optimizer-test.dir/optimizer-test.cpp.o] Error 1
make[1]: *** [CMakeFiles/Makefile2:210: test/CMakeFiles/optimizer-test.dir/all] Error 2
make: *** [Makefile:141: all] Error 2

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant