Kinovarobotics / ros_kortex

ROS packages for KINOVA® KORTEX™ robotic arms
Other
160 stars 159 forks source link

build error of ros_kortex in docker #255

Closed patrickwasp closed 1 year ago

patrickwasp commented 2 years ago

Description

ros_kortex 2.3.0 fails to build

Version

ROS distribution : noetic

Branch and commit you are using : 2.3.0

Steps to reproduce

  1. run docker build --file ros_kortex.dockerfile .

Code example (if necessary)

ros_kortex.dockerfile

FROM osrf/ros:noetic-desktop-full

SHELL ["/bin/bash", "-c"]
ENV DEBIAN_FRONTEND=noninteractive

RUN apt-get update && apt-get upgrade --yes

RUN apt-get update && apt-get --yes install \
    wget \
    python3 \
    python3-pip \
    python3-catkin-tools

RUN sudo python3 -m pip install conan==1.52.0

RUN mkdir -p /catkin_ws/src
WORKDIR /catkin_ws

RUN conan config set general.revisions_enabled=1 \
    && conan profile new default --detect > /dev/null \
    && conan profile update settings.compiler.libcxx=libstdc++11 default

RUN wget -c https://github.com/Kinovarobotics/ros_kortex/archive/refs/tags/v2.3.0.tar.gz -O - | tar -xz -C /catkin_ws/src
RUN mv /catkin_ws/src/ros_kortex-2.3.0 /catkin_ws/src/ros_kortex

RUN rosdep install --from-paths src --ignore-src -y

RUN catkin config --extend /opt/ros/$ROS_DISTRO \
    && catkin config --cmake-args -DCMAKE_BUILD_TYPE=Release \
    && catkin build

Expected behavior

Successful compile of ros_kortex package.

Any other information

Buid output:

Step 13/13 : RUN catkin config --extend /opt/ros/$ROS_DISTRO     && catkin config --cmake-args -DCMAKE_BUILD_TYPE=Release     && catkin build
 ---> Running in 096b02f0110e
-----------------------------------------------
Profile:                     default
Extending:        [explicit] /opt/ros/noetic
Workspace:                   /catkin_ws
-----------------------------------------------
Build Space:       [missing] /catkin_ws/build
Devel Space:       [missing] /catkin_ws/devel
Install Space:      [unused] /catkin_ws/install
Log Space:         [missing] /catkin_ws/logs
Source Space:       [exists] /catkin_ws/src
DESTDIR:            [unused] None
-----------------------------------------------
Devel Space Layout:          linked
Install Space Layout:        None
-----------------------------------------------
Additional CMake Args:       None
Additional Make Args:        None
Additional catkin Make Args: None
Internal Make Job Server:    True
Cache Job Environments:      False
-----------------------------------------------
Buildlisted Packages:        None
Skiplisted Packages:         None
-----------------------------------------------
Workspace configuration appears valid.

Initialized new catkin workspace in `/catkin_ws`
-----------------------------------------------
-------------------------------------------------------
Profile:                     default
Extending:        [explicit] /opt/ros/noetic
Workspace:                   /catkin_ws
-------------------------------------------------------
Build Space:       [missing] /catkin_ws/build
Devel Space:       [missing] /catkin_ws/devel
Install Space:      [unused] /catkin_ws/install
Log Space:         [missing] /catkin_ws/logs
Source Space:       [exists] /catkin_ws/src
DESTDIR:            [unused] None
-------------------------------------------------------
Devel Space Layout:          linked
Install Space Layout:        None
-------------------------------------------------------
Additional CMake Args:       -DCMAKE_BUILD_TYPE=Release
Additional Make Args:        None
Additional catkin Make Args: None
Internal Make Job Server:    True
Cache Job Environments:      False
-------------------------------------------------------
Buildlisted Packages:        None
Skiplisted Packages:         None
-------------------------------------------------------
Workspace configuration appears valid.
-------------------------------------------------------
-------------------------------------------------------
Profile:                     default
Extending:        [explicit] /opt/ros/noetic
Workspace:                   /catkin_ws
-------------------------------------------------------
Build Space:        [exists] /catkin_ws/build
Devel Space:        [exists] /catkin_ws/devel
Install Space:      [unused] /catkin_ws/install
Log Space:         [missing] /catkin_ws/logs
Source Space:       [exists] /catkin_ws/src
DESTDIR:            [unused] None
-------------------------------------------------------
Devel Space Layout:          linked
Install Space Layout:        None
-------------------------------------------------------
Additional CMake Args:       -DCMAKE_BUILD_TYPE=Release
Additional Make Args:        None
Additional catkin Make Args: None
Internal Make Job Server:    True
Cache Job Environments:      False
-------------------------------------------------------
Buildlisted Packages:        None
Skiplisted Packages:         None
-------------------------------------------------------
Workspace configuration appears valid.

NOTE: Forcing CMake to run for each package.
-------------------------------------------------------
[build] Found 13 packages in 0.0 seconds.                                      
[build] Updating package table.                                                
Starting >>> catkin_tools_prebuild                                             
Finished <<< catkin_tools_prebuild                                [ 1.3 seconds ]
Starting >>> gazebo_version_helpers                                            
Starting >>> kortex_control                                                    
Starting >>> kortex_description                                                
Starting >>> kortex_driver                                                     
Starting >>> roboticsgroup_gazebo_plugins                                      
Finished <<< kortex_description                                   [ 1.1 seconds ]
Starting >>> gen3_lite_gen3_lite_2f_move_it_config                             
Starting >>> gen3_move_it_config                                               
Starting >>> gen3_robotiq_2f_140_move_it_config                                
Starting >>> gen3_robotiq_2f_85_move_it_config                                 
Starting >>> kortex_move_it_config                                             
Finished <<< kortex_control                                       [ 1.1 seconds ]
Finished <<< kortex_move_it_config                                [ 1.2 seconds ]
Finished <<< gen3_robotiq_2f_140_move_it_config                   [ 1.3 seconds ]
Finished <<< gen3_move_it_config                                  [ 1.3 seconds ]
Finished <<< gen3_robotiq_2f_85_move_it_config                    [ 1.3 seconds ]
Finished <<< gen3_lite_gen3_lite_2f_move_it_config                [ 1.3 seconds ]
_______________________________________________________________________________
Warnings << gazebo_version_helpers:cmake /catkin_ws/logs/gazebo_version_helpers/build.cmake.000.log
CMake Warning at /opt/ros/noetic/share/catkin/cmake/catkin_package.cmake:166 (message):
  catkin_package() DEPENDS on 'gazebo' but neither 'gazebo_INCLUDE_DIRS' nor
  'gazebo_LIBRARIES' is defined.
Call Stack (most recent call first):
  /opt/ros/noetic/share/catkin/cmake/catkin_package.cmake:102 (_catkin_package)
  CMakeLists.txt:29 (catkin_package)

cd /catkin_ws/build/gazebo_version_helpers; catkin build --get-env gazebo_version_helpers | catkin env -si  /usr/bin/cmake /catkin_ws/src/ros_kortex/third_party/gazebo-pkgs/gazebo_version_helpers --no-warn-unused-cli -DCATKIN_DEVEL_PREFIX=/catkin_ws/devel/.private/gazebo_version_helpers -DCMAKE_INSTALL_PREFIX=/catkin_ws/install -DCMAKE_BUILD_TYPE=Release; cd -

...............................................................................
_______________________________________________________________________________
Warnings << kortex_driver:cmake /catkin_ws/logs/kortex_driver/build.cmake.000.log
CONAN_TARGET_PLATFORM is x86
WARN: Remotes registry file missing, creating default one in /root/.conan/remotes.json
cd /catkin_ws/build/kortex_driver; catkin build --get-env kortex_driver | catkin env -si  /usr/bin/cmake /catkin_ws/src/ros_kortex/kortex_driver --no-warn-unused-cli -DCATKIN_DEVEL_PREFIX=/catkin_ws/devel/.private/kortex_driver -DCMAKE_INSTALL_PREFIX=/catkin_ws/install -DCMAKE_BUILD_TYPE=Release; cd -

...............................................................................
_______________________________________________________________________________
Errors << gazebo_version_helpers:make /catkin_ws/logs/gazebo_version_helpers/build.make.000.log
In file included from /usr/include/ignition/math6/gz/math/Spline.hh:22,
                 from /usr/include/ignition/math6/ignition/math/Spline.hh:18,
                 from /usr/include/gazebo-11/gazebo/common/Animation.hh:22,
                 from /usr/include/gazebo-11/gazebo/common/common.hh:5,
                 from /usr/include/gazebo-11/gazebo/gazebo_core.hh:19,
                 from /usr/include/gazebo-11/gazebo/gazebo.hh:20,
                 from /catkin_ws/src/ros_kortex/third_party/gazebo-pkgs/gazebo_version_helpers/include/gazebo_version_helpers/GazeboVersionHelpers.h:4,
                 from /catkin_ws/src/ros_kortex/third_party/gazebo-pkgs/gazebo_version_helpers/src/GazeboVersionHelpers.cpp:1:
/usr/include/ignition/math6/gz/math/Helpers.hh:40:13: warning: variable templates only available with ‘-std=c++14’ or ‘-std=gnu++14’
   40 | constexpr T IGN_MASSMATRIX3_DEFAULT_TOLERANCE = T(10);
      |             ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
/usr/include/ignition/math6/gz/math/Helpers.hh: In function ‘std::chrono::_V2::steady_clock::duration ignition::math::v6::stringToDuration(const string&)’:
/usr/include/ignition/math6/gz/math/Helpers.hh:1059:28: error: ‘chrono_literals’ is not a namespace-name
 1059 |       using namespace std::chrono_literals;
      |                            ^~~~~~~~~~~~~~~
/usr/include/ignition/math6/gz/math/Helpers.hh: In function ‘std::chrono::_V2::steady_clock::time_point ignition::math::v6::stringToTimePoint(const string&)’:
/usr/include/ignition/math6/gz/math/Helpers.hh:1101:28: error: ‘chrono_literals’ is not a namespace-name
 1101 |       using namespace std::chrono_literals;
      |                            ^~~~~~~~~~~~~~~
/usr/include/ignition/math6/gz/math/Helpers.hh:1102:56: error: unable to find numeric literal operator ‘operator""s’
 1102 |       std::chrono::steady_clock::time_point timePoint{-1s};
      |                                                        ^~
/usr/include/ignition/math6/gz/math/Helpers.hh:1102:56: note: use ‘-fext-numeric-literals’ to enable more built-in suffixes
/usr/include/ignition/math6/gz/math/Helpers.hh:1102:58: error: no matching function for call to ‘std::chrono::time_point<std::chrono::_V2::steady_clock, std::chrono::duration<long int, std::ratio<1, 1000000000> > >::time_point(<brace-enclosed initializer list>)’
 1102 |       std::chrono::steady_clock::time_point timePoint{-1s};
      |                                                          ^
In file included from /usr/include/ignition/math6/gz/math/Helpers.hh:21,
                 from /usr/include/ignition/math6/gz/math/Spline.hh:22,
                 from /usr/include/ignition/math6/ignition/math/Spline.hh:18,
                 from /usr/include/gazebo-11/gazebo/common/Animation.hh:22,
                 from /usr/include/gazebo-11/gazebo/common/common.hh:5,
                 from /usr/include/gazebo-11/gazebo/gazebo_core.hh:19,
                 from /usr/include/gazebo-11/gazebo/gazebo.hh:20,
                 from /catkin_ws/src/ros_kortex/third_party/gazebo-pkgs/gazebo_version_helpers/include/gazebo_version_helpers/GazeboVersionHelpers.h:4,
                 from /catkin_ws/src/ros_kortex/third_party/gazebo-pkgs/gazebo_version_helpers/src/GazeboVersionHelpers.cpp:1:
/usr/include/c++/9/chrono:643:14: note: candidate: ‘template<class _Dur2, class> constexpr std::chrono::time_point<_Clock, _Dur>::time_point(const std::chrono::time_point<_Clock, _Dur2>&)’
  643 |    constexpr time_point(const time_point<clock, _Dur2>& __t)
      |              ^~~~~~~~~~
/usr/include/c++/9/chrono:643:14: note:   template argument deduction/substitution failed:
/usr/include/c++/9/chrono:636:21: note: candidate: ‘constexpr std::chrono::time_point<_Clock, _Dur>::time_point(const duration&) [with _Clock = std::chrono::_V2::steady_clock; _Dur = std::chrono::duration<long int, std::ratio<1, 1000000000> >; std::chrono::time_point<_Clock, _Dur>::duration = std::chrono::duration<long int, std::ratio<1, 1000000000> >]’
  636 |  constexpr explicit time_point(const duration& __dur)
      |                     ^~~~~~~~~~
/usr/include/c++/9/chrono:636:21: note:   conversion of argument 1 would be ill-formed:
/usr/include/c++/9/chrono:633:12: note: candidate: ‘constexpr std::chrono::time_point<_Clock, _Dur>::time_point() [with _Clock = std::chrono::_V2::steady_clock; _Dur = std::chrono::duration<long int, std::ratio<1, 1000000000> >]’
  633 |  constexpr time_point() : __d(duration::zero())
      |            ^~~~~~~~~~
/usr/include/c++/9/chrono:633:12: note:   candidate expects 0 arguments, 1 provided
/usr/include/c++/9/chrono:626:14: note: candidate: ‘constexpr std::chrono::time_point<std::chrono::_V2::steady_clock, std::chrono::duration<long int, std::ratio<1, 1000000000> > >::time_point(const std::chrono::time_point<std::chrono::_V2::steady_clock, std::chrono::duration<long int, std::ratio<1, 1000000000> > >&)’
  626 |       struct time_point
      |              ^~~~~~~~~~
/usr/include/c++/9/chrono:626:14: note:   conversion of argument 1 would be ill-formed:
/usr/include/c++/9/chrono:626:14: note: candidate: ‘constexpr std::chrono::time_point<std::chrono::_V2::steady_clock, std::chrono::duration<long int, std::ratio<1, 1000000000> > >::time_point(std::chrono::time_point<std::chrono::_V2::steady_clock, std::chrono::duration<long int, std::ratio<1, 1000000000> > >&&)’
/usr/include/c++/9/chrono:626:14: note:   conversion of argument 1 would be ill-formed:
In file included from /usr/include/ignition/math6/gz/math/Region3.hh:25,
                 from /usr/include/ignition/math6/gz/math/AdditivelySeparableScalarField3.hh:23,
                 from /usr/include/ignition/math6/gz/math.hh:27,
                 from /usr/include/ignition/math6/ignition/math.hh:18,
                 from /usr/include/sdformat-9.8/sdf/Param.hh:33,
                 from /usr/include/sdformat-9.8/sdf/Element.hh:28,
                 from /usr/include/sdformat-9.8/sdf/Actor.hh:25,
                 from /usr/include/sdformat-9.8/sdf/sdf.hh:2,
                 from /usr/include/gazebo-11/gazebo/common/Battery.hh:25,
                 from /usr/include/gazebo-11/gazebo/common/common.hh:8,
                 from /usr/include/gazebo-11/gazebo/gazebo_core.hh:19,
                 from /usr/include/gazebo-11/gazebo/gazebo.hh:20,
                 from /catkin_ws/src/ros_kortex/third_party/gazebo-pkgs/gazebo_version_helpers/include/gazebo_version_helpers/GazeboVersionHelpers.h:4,
                 from /catkin_ws/src/ros_kortex/third_party/gazebo-pkgs/gazebo_version_helpers/src/GazeboVersionHelpers.cpp:1:
/usr/include/ignition/math6/gz/math/Interval.hh: At global scope:
/usr/include/ignition/math6/gz/math/Interval.hh:286:30: warning: variable templates only available with ‘-std=c++14’ or ‘-std=gnu++14’
  286 |        constexpr Interval<T> gUnboundedInterval =
      |                              ^~~~~~~~~~~~~~~~~~
In file included from /usr/include/ignition/math6/gz/math/AdditivelySeparableScalarField3.hh:23,
                 from /usr/include/ignition/math6/gz/math.hh:27,
                 from /usr/include/ignition/math6/ignition/math.hh:18,
                 from /usr/include/sdformat-9.8/sdf/Param.hh:33,
                 from /usr/include/sdformat-9.8/sdf/Element.hh:28,
                 from /usr/include/sdformat-9.8/sdf/Actor.hh:25,
                 from /usr/include/sdformat-9.8/sdf/sdf.hh:2,
                 from /usr/include/gazebo-11/gazebo/common/Battery.hh:25,
                 from /usr/include/gazebo-11/gazebo/common/common.hh:8,
                 from /usr/include/gazebo-11/gazebo/gazebo_core.hh:19,
                 from /usr/include/gazebo-11/gazebo/gazebo.hh:20,
                 from /catkin_ws/src/ros_kortex/third_party/gazebo-pkgs/gazebo_version_helpers/include/gazebo_version_helpers/GazeboVersionHelpers.h:4,
                 from /catkin_ws/src/ros_kortex/third_party/gazebo-pkgs/gazebo_version_helpers/src/GazeboVersionHelpers.cpp:1:
/usr/include/ignition/math6/gz/math/Region3.hh:192:29: warning: variable templates only available with ‘-std=c++14’ or ‘-std=gnu++14’
  192 |        constexpr Region3<T> gUnboundedRegion3(
      |                             ^~~~~~~~~~~~~~~~~
In file included from /usr/include/ignition/math6/gz/math/Box.hh:23,
                 from /usr/include/ignition/math6/gz/math.hh:30,
                 from /usr/include/ignition/math6/ignition/math.hh:18,
                 from /usr/include/sdformat-9.8/sdf/Param.hh:33,
                 from /usr/include/sdformat-9.8/sdf/Element.hh:28,
                 from /usr/include/sdformat-9.8/sdf/Actor.hh:25,
                 from /usr/include/sdformat-9.8/sdf/sdf.hh:2,
                 from /usr/include/gazebo-11/gazebo/common/Battery.hh:25,
                 from /usr/include/gazebo-11/gazebo/common/common.hh:8,
                 from /usr/include/gazebo-11/gazebo/gazebo_core.hh:19,
                 from /usr/include/gazebo-11/gazebo/gazebo.hh:20,
                 from /catkin_ws/src/ros_kortex/third_party/gazebo-pkgs/gazebo_version_helpers/include/gazebo_version_helpers/GazeboVersionHelpers.h:4,
                 from /catkin_ws/src/ros_kortex/third_party/gazebo-pkgs/gazebo_version_helpers/src/GazeboVersionHelpers.cpp:1:
/usr/include/ignition/math6/gz/math/Plane.hh:133:20: error: ‘optional’ in namespace ‘std’ does not name a template type
  133 |       public: std::optional<Vector3<T>> Intersection(
      |                    ^~~~~~~~
/usr/include/ignition/math6/gz/math/Plane.hh:133:15: note: ‘std::optional’ is only available from C++17 onwards
  133 |       public: std::optional<Vector3<T>> Intersection(
      |               ^~~
In file included from /usr/include/ignition/math6/gz/math.hh:30,
                 from /usr/include/ignition/math6/ignition/math.hh:18,
                 from /usr/include/sdformat-9.8/sdf/Param.hh:33,
                 from /usr/include/sdformat-9.8/sdf/Element.hh:28,
                 from /usr/include/sdformat-9.8/sdf/Actor.hh:25,
                 from /usr/include/sdformat-9.8/sdf/sdf.hh:2,
                 from /usr/include/gazebo-11/gazebo/common/Battery.hh:25,
                 from /usr/include/gazebo-11/gazebo/common/common.hh:8,
                 from /usr/include/gazebo-11/gazebo/gazebo_core.hh:19,
                 from /usr/include/gazebo-11/gazebo/gazebo.hh:20,
                 from /catkin_ws/src/ros_kortex/third_party/gazebo-pkgs/gazebo_version_helpers/include/gazebo_version_helpers/GazeboVersionHelpers.h:4,
                 from /catkin_ws/src/ros_kortex/third_party/gazebo-pkgs/gazebo_version_helpers/src/GazeboVersionHelpers.cpp:1:
/usr/include/ignition/math6/gz/math/Box.hh:151:20: error: ‘optional’ in namespace ‘std’ does not name a template type
  151 |       public: std::optional<Vector3<Precision>>
      |                    ^~~~~~~~
/usr/include/ignition/math6/gz/math/Box.hh:151:15: note: ‘std::optional’ is only available from C++17 onwards
  151 |       public: std::optional<Vector3<Precision>>
      |               ^~~
In file included from /usr/include/ignition/math6/gz/math/Box.hh:224,
                 from /usr/include/ignition/math6/gz/math.hh:30,
                 from /usr/include/ignition/math6/ignition/math.hh:18,
                 from /usr/include/sdformat-9.8/sdf/Param.hh:33,
                 from /usr/include/sdformat-9.8/sdf/Element.hh:28,
                 from /usr/include/sdformat-9.8/sdf/Actor.hh:25,
                 from /usr/include/sdformat-9.8/sdf/sdf.hh:2,
                 from /usr/include/gazebo-11/gazebo/common/Battery.hh:25,
                 from /usr/include/gazebo-11/gazebo/common/common.hh:8,
                 from /usr/include/gazebo-11/gazebo/gazebo_core.hh:19,
                 from /usr/include/gazebo-11/gazebo/gazebo.hh:20,
                 from /catkin_ws/src/ros_kortex/third_party/gazebo-pkgs/gazebo_version_helpers/include/gazebo_version_helpers/GazeboVersionHelpers.h:4,
                 from /catkin_ws/src/ros_kortex/third_party/gazebo-pkgs/gazebo_version_helpers/src/GazeboVersionHelpers.cpp:1:
/usr/include/ignition/math6/gz/math/detail/Box.hh:237:6: error: ‘optional’ in namespace ‘std’ does not name a template type
  237 | std::optional<Vector3<T>>
      |      ^~~~~~~~
/usr/include/ignition/math6/gz/math/detail/Box.hh:237:1: note: ‘std::optional’ is only available from C++17 onwards
  237 | std::optional<Vector3<T>>
      | ^~~
In file included from /usr/include/ignition/math6/gz/math.hh:31,
                 from /usr/include/ignition/math6/ignition/math.hh:18,
                 from /usr/include/sdformat-9.8/sdf/Param.hh:33,
                 from /usr/include/sdformat-9.8/sdf/Element.hh:28,
                 from /usr/include/sdformat-9.8/sdf/Actor.hh:25,
                 from /usr/include/sdformat-9.8/sdf/sdf.hh:2,
                 from /usr/include/gazebo-11/gazebo/common/Battery.hh:25,
                 from /usr/include/gazebo-11/gazebo/common/common.hh:8,
                 from /usr/include/gazebo-11/gazebo/gazebo_core.hh:19,
                 from /usr/include/gazebo-11/gazebo/gazebo.hh:20,
                 from /catkin_ws/src/ros_kortex/third_party/gazebo-pkgs/gazebo_version_helpers/include/gazebo_version_helpers/GazeboVersionHelpers.h:4,
                 from /catkin_ws/src/ros_kortex/third_party/gazebo-pkgs/gazebo_version_helpers/src/GazeboVersionHelpers.cpp:1:
/usr/include/ignition/math6/gz/math/Capsule.hh:91:20: error: ‘optional’ in namespace ‘std’ does not name a template type
   91 |       public: std::optional< MassMatrix3<Precision> > MassMatrix() const;
      |                    ^~~~~~~~
/usr/include/ignition/math6/gz/math/Capsule.hh:91:15: note: ‘std::optional’ is only available from C++17 onwards
   91 |       public: std::optional< MassMatrix3<Precision> > MassMatrix() const;
      |               ^~~
In file included from /usr/include/ignition/math6/gz/math/Capsule.hh:149,
                 from /usr/include/ignition/math6/gz/math.hh:31,
                 from /usr/include/ignition/math6/ignition/math.hh:18,
                 from /usr/include/sdformat-9.8/sdf/Param.hh:33,
                 from /usr/include/sdformat-9.8/sdf/Element.hh:28,
                 from /usr/include/sdformat-9.8/sdf/Actor.hh:25,
                 from /usr/include/sdformat-9.8/sdf/sdf.hh:2,
                 from /usr/include/gazebo-11/gazebo/common/Battery.hh:25,
                 from /usr/include/gazebo-11/gazebo/common/common.hh:8,
                 from /usr/include/gazebo-11/gazebo/gazebo_core.hh:19,
                 from /usr/include/gazebo-11/gazebo/gazebo.hh:20,
                 from /catkin_ws/src/ros_kortex/third_party/gazebo-pkgs/gazebo_version_helpers/include/gazebo_version_helpers/GazeboVersionHelpers.h:4,
                 from /catkin_ws/src/ros_kortex/third_party/gazebo-pkgs/gazebo_version_helpers/src/GazeboVersionHelpers.cpp:1:
/usr/include/ignition/math6/gz/math/detail/Capsule.hh:100:6: error: ‘optional’ in namespace ‘std’ does not name a template type
  100 | std::optional< MassMatrix3<T> > Capsule<T>::MassMatrix() const
      |      ^~~~~~~~
/usr/include/ignition/math6/gz/math/detail/Capsule.hh:100:1: note: ‘std::optional’ is only available from C++17 onwards
  100 | std::optional< MassMatrix3<T> > Capsule<T>::MassMatrix() const
      | ^~~
In file included from /usr/include/ignition/math6/gz/math.hh:35,
                 from /usr/include/ignition/math6/ignition/math.hh:18,
                 from /usr/include/sdformat-9.8/sdf/Param.hh:33,
                 from /usr/include/sdformat-9.8/sdf/Element.hh:28,
                 from /usr/include/sdformat-9.8/sdf/Actor.hh:25,
                 from /usr/include/sdformat-9.8/sdf/sdf.hh:2,
                 from /usr/include/gazebo-11/gazebo/common/Battery.hh:25,
                 from /usr/include/gazebo-11/gazebo/common/common.hh:8,
                 from /usr/include/gazebo-11/gazebo/gazebo_core.hh:19,
                 from /usr/include/gazebo-11/gazebo/gazebo.hh:20,
                 from /catkin_ws/src/ros_kortex/third_party/gazebo-pkgs/gazebo_version_helpers/include/gazebo_version_helpers/GazeboVersionHelpers.h:4,
                 from /catkin_ws/src/ros_kortex/third_party/gazebo-pkgs/gazebo_version_helpers/src/GazeboVersionHelpers.cpp:1:
/usr/include/ignition/math6/gz/math/Ellipsoid.hh:77:20: error: ‘optional’ in namespace ‘std’ does not name a template type
   77 |       public: std::optional< MassMatrix3<Precision> > MassMatrix() const;
      |                    ^~~~~~~~
/usr/include/ignition/math6/gz/math/Ellipsoid.hh:77:15: note: ‘std::optional’ is only available from C++17 onwards
   77 |       public: std::optional< MassMatrix3<Precision> > MassMatrix() const;
      |               ^~~
In file included from /usr/include/ignition/math6/gz/math/Ellipsoid.hh:132,
                 from /usr/include/ignition/math6/gz/math.hh:35,
                 from /usr/include/ignition/math6/ignition/math.hh:18,
                 from /usr/include/sdformat-9.8/sdf/Param.hh:33,
                 from /usr/include/sdformat-9.8/sdf/Element.hh:28,
                 from /usr/include/sdformat-9.8/sdf/Actor.hh:25,
                 from /usr/include/sdformat-9.8/sdf/sdf.hh:2,
                 from /usr/include/gazebo-11/gazebo/common/Battery.hh:25,
                 from /usr/include/gazebo-11/gazebo/common/common.hh:8,
                 from /usr/include/gazebo-11/gazebo/gazebo_core.hh:19,
                 from /usr/include/gazebo-11/gazebo/gazebo.hh:20,
                 from /catkin_ws/src/ros_kortex/third_party/gazebo-pkgs/gazebo_version_helpers/include/gazebo_version_helpers/GazeboVersionHelpers.h:4,
                 from /catkin_ws/src/ros_kortex/third_party/gazebo-pkgs/gazebo_version_helpers/src/GazeboVersionHelpers.cpp:1:
/usr/include/ignition/math6/gz/math/detail/Ellipsoid.hh:77:6: error: ‘optional’ in namespace ‘std’ does not name a template type
   77 | std::optional< MassMatrix3<T> > Ellipsoid<T>::MassMatrix() const
      |      ^~~~~~~~

...

/usr/include/sdformat-9.8/sdf/Param.hh: In member function ‘std::string sdf::v9::ParamPrivate::TypeToString() const [with T = double]’:
/usr/include/sdformat-9.8/sdf/Param.hh:320:3: warning: control reaches end of non-void function [-Wreturn-type]
make[2]: *** [CMakeFiles/roboticsgroup_gazebo_mimic_joint_plugin.dir/build.make:63: CMakeFiles/roboticsgroup_gazebo_mimic_joint_plugin.dir/src/mimic_joint_plugin.cpp.o] Error 1
make[1]: *** [CMakeFiles/Makefile2:220: CMakeFiles/roboticsgroup_gazebo_mimic_joint_plugin.dir/all] Error 2
make: *** [Makefile:141: all] Error 2
cd /catkin_ws/build/roboticsgroup_gazebo_plugins; catkin build --get-env roboticsgroup_gazebo_plugins | catkin env -si  /usr/bin/make --jobserver-auth=3,4; cd -
Failed <<< roboticsgroup_gazebo_plugins                         [ 10.1 seconds ]
[build 02:26.1 s] [10/14 complete] [1/16 jobs] [0 queued] [2 failed] [korte... 
...............................................................................
Failed << roboticsgroup_gazebo_plugins:make                     [ Exited with code 2 ]
Finished <<< kortex_driver                                        [ 2 minutes and 24.6 seconds ]
[build] Summary: 9 of 14 packages succeeded.                                   
[build] Ignored: None.                                                         
[build] Warnings: 2 packages succeeded with warnings.                          
[build] Abandoned: 3 packages were abandoned.                                  
[build] Failed: 2 packages failed.                                             
[build] Runtime: 2 minutes and 26.2 seconds total.                             
[build] Note: Workspace packages have changed, please re-source setup files to use them.
The command '/bin/bash -c catkin config --extend /opt/ros/$ROS_DISTRO     && catkin config --cmake-args -DCMAKE_BUILD_TYPE=Release     && catkin build' returned a non-zero code: 1
felixmaisonneuve commented 2 years ago

Hi @patrickwasp,

I will link the issue #166 that seems to be the same errors as you. Basically, you are using a commit from before we added support for ROS Noetic I will suggest changing

https://github.com/Kinovarobotics/ros_kortex/archive/refs/tags/v2.3.0.tar.gz

to

https://github.com/Kinovarobotics/ros_kortex/archive/refs/heads/noetic-devel.zip

in your dockerfile to download the latest commit from our noetic-devel

It sould fix your issue.

Regards, Felix

felixmaisonneuve commented 1 year ago

Hi @patrickwasp,

I will assume this fixed the issue and close it. If it is not the case, feel free to re-open the issue or comment and I will help you

Regards, Felix