ros1 bridge encounter ros2 colcon error

--- stderr: qt_gui_cpp                                                                                                                                  
make[3]: warning: jobserver unavailable: using -j1.  Add '+' to parent make rule.
In file included from siplibqt_gui_cpp_sipcmodule.cpp:7:0:
sipAPIlibqt_gui_cpp_sip.h:11:17: fatal error: sip.h: No such file or directory
compilation terminated.
make[3]: *** [siplibqt_gui_cpp_sipcmodule.o] Error 1
make[2]: *** [src/qt_gui_cpp_sip/libqt_gui_cpp_sip.so] Error 2
make[1]: *** [src/qt_gui_cpp_sip/CMakeFiles/libqt_gui_cpp_sip.dir/all] Error 2
make[1]: *** Waiting for unfinished jobs....
make: *** [all] Error 2
---
Failed   <<< qt_gui_cpp	[ Exited with code 2 ]
Aborted  <<< rviz_rendering
Aborted  <<< rmw_fastrtps_shared_cpp
Aborted  <<< ament_pep8
[48.195s] ERROR:colcon.colcon_core.event_reactor:Exception in event handler extension 'status': 
Traceback (most recent call last):
  File "/usr/lib/python3/dist-packages/colcon_core/event_reactor.py", line 78, in _notify_observers
    retval = observer(event)
  File "/usr/lib/python3/dist-packages/colcon_notification/event_handler/status.py", line 109, in __call__
    progress = self._running[job].get('progress', [])
KeyError: 

解决办法:

sudo apt install python3-sip-dev

如果还不行,说明你是在编译了ros2之后又重新编译的,系统环境变量已经被ros2的local_setup.bash改变,因此,需要在terminal中

source /opt/ros//setup.bash

然后再重新编译就好啦

最后ros1_bridge终于编译好了。
在这里插入图片描述

你可能感兴趣的:(ros2)