zakjma
zakjma

Reputation: 2110

No such file or directory but file exist

I installed pcl. There is a pcl folder under user/include/pcl-1.7. I add #include <pcl/ModelCoefficients.h> line to cpp file. On terminal, I try to compile this file.

g++ -c test.cpp 
fatal error: pcl/ModelCoefficients.h: No such file or directory
#include <pcl/ModelCoefficients.h>
                               ^
compilation terminated.

How can I solve this error?

Upvotes: 0

Views: 8220

Answers (1)

Emil Laine
Emil Laine

Reputation: 42828

Use -I to tell the compiler to search the user/include/plc-1.7 path for header files:

g++ -Iuser/include/plc-1.7 -c test.cpp 

More info:

Upvotes: 1

Related Questions