来源:https://github.com/hku-mars/livox_camera_calib/issues/82
我自己的报错截图和内容没有保存,但是出现的问题和该问题链接一模一样,直接放上该提问链接的内容。
报错:In file included from /opt/ros /melodic/include/roslz4/lz4s. h:38:0,
from /opt/ros/melodic/include/rosbag/stream.h:46,
from /opt/ros/melodic/tnclude/rosbag/chunked_ file.h:46,
from /opt/ros/melodic/include/rosbag/bag.h:41,
from /hone/yanglin/catktn_ ws/src/ltvox_ camera_ calib/include/lidar_ canera_ calib. hpp:25,from /hone/yanglin/catktn_ ws/src/livox_ camera_ calib/src/lidar_ camera_ calib. cpp:1:
/usr/include/lz4. h:196:57: error: conflicting declaration_ . typedef struct LZ4_ stream_ t LZ4_ stream t’typedef struct f long long table[LZ4 STREAMSIZE U64]; 2 LZ4 strean t;
解决方法:
sudo mv /usr/include/flann/ext/lz4.h /usr/include/flann/ext/lz4.h.bak
sudo mv /usr/include/flann/ext/lz4hc.h /usr/include/flann/ext/lz4.h.bak
sudo ln -s /usr/include/lz4.h /usr/include/flann/ext/lz4.h
sudo ln -s /usr/include/lz4hc.h /usr/include/flann/ext/lz4hc.h