--- stderr: ueye_cam
/home/sg-atcoe-23761/ws_scannerbot/src/driver/ueye_cam/src/driver/driver.cpp: In static member function ‘static const string ueye_cam::Driver::colormode2name(INT)’:
/home/sg-atcoe-23761/ws_scannerbot/src/driver/ueye_cam/src/driver/driver.cpp:1873:43: error: loop variable ‘value’ of type ‘const std::pair<std::__cxx11::basic_string<char>, int>&’ binds to a temporary constructed from type ‘const std::pair<const std::__cxx11::basic_string<char>, int>’ [-Werror=range-loop-construct]
1873 | for (const std::pair<std::string, INT>& value: COLOR_DICTIONARY) {
| ^~~~~
/home/sg-atcoe-23761/ws_scannerbot/src/driver/ueye_cam/src/driver/driver.cpp:1873:43: note: use non-reference type ‘const std::pair<std::__cxx11::basic_string<char>, int>’ to make the copy explicit or ‘const std::pair<const std::__cxx11::basic_string<char>, int>&’ to prevent copying
cc1plus: all warnings being treated as errors
gmake[2]: *** [src/driver/CMakeFiles/ueye_cam_driver.dir/build.make:76: src/driver/CMakeFiles/ueye_cam_driver.dir/driver.cpp.o] Error 1
gmake[1]: *** [CMakeFiles/Makefile2:240: src/driver/CMakeFiles/ueye_cam_driver.dir/all] Error 2
gmake: *** [Makefile:146: all] Error 2
---
Failed <<< ueye_cam [0.49s, exited with code 2]
I encounter error while building the
ueye_campackage in ROS2My environment:
Error message: