HesaiTechnology / HesaiLidar_General_ROS

ROS driver for PandarXT PandarQT Pandar64 Pandar40P Pandar40M Pandar20A Pandar20B
Other
158 stars 102 forks source link

PandarScan.h: No such file or directory #24

Open philRudd69 opened 3 years ago

philRudd69 commented 3 years ago

Hi

we experience the following error whilst compiling the newest version of this repo:

In file included from /catkin_ws/src/HesaiLidar_General_ROS/src/HesaiLidar_General_SDK/src/PandarGeneralRaw/src/pandarGeneral_internal.cc:20:0:
/catkin_ws/src/HesaiLidar_General_ROS/src/HesaiLidar_General_SDK/src/PandarGeneralRaw/src/pandarGeneral_internal.h:35:10: fatal error: hesai_lidar/PandarScan.h: No such file or directory
 #include "hesai_lidar/PandarScan.h"

We can only solve this by compiling the workspace a second time. Any ideas?

Cheers

Markus

DK-sr commented 3 years ago

I had the same issue and fixed it by adding one add dependency line in CMakeLists.txt. Currently, I made pull requests about this. Please check here.

yangfanFred commented 3 years ago

Thanks guys,

We will review and test the code

Thanks, Fred

Shelfcol commented 3 years ago

this answer works for me. https://github.com/HesaiTechnology/HesaiLidar_General_ROS/commit/7aae245c970af3fa294cee49221a39dfe2cca6fe

src/HesaiLidar_General_SDK/src/PandarGeneralRaw/src/pcap_reader.cpp
src/HesaiLidar_General_SDK/src/PandarGeneralRaw/src/pandarGeneral.cc

)

(add this!!!!) add_dependencies(PandarGeneral hesai_lidar_generate_messages_cpp)

target_include_directories(PandarGeneral PRIVATE src/HesaiLidar_General_SDK/src/PandarGeneralRaw/include src/HesaiLidar_General_SDK/src/PandarGeneralRaw/