Eclipse cdt not see header files in project packages?

I try to compile the project, but I immediately get an error message that it does not see the header files that are in some packages inside the project. Here is the image, note that it does not find the AwarenessMoment.h file, however it is there.

error

Here is the conclusion:

**** Build of configuration Debug for project RoyOS **** make all Building file: ../src/royos/vision/ImageRecognizer.cpp Invoking: GCC C++ Compiler g++ -I/home/igvc/Documents/teamigvc/trunk/RoyOS -O0 -g3 -Wall -c -fmessage-length=0 -MMD -MP -MF"src/royos/vision/ImageRecognizer.d" -MT"src/royos/vision/ImageRecognizer.d" -o"src/royos/vision/ImageRecognizer.o" "../src/royos/vision/ImageRecognizer.cpp" In file included from ../src/royos/vision/ImageRecognizer.cpp:8:0: ../src/royos/vision/ImageRecognizer.h:11:29: fatal error: AwarenessMoment.h: No such file or directory compilation terminated. make: *** [src/royos/vision/ImageRecognizer.o] Error 1 

Does anyone know why he does not see these header files?

thanks

+4
source share
1 answer

There is definitely something wrong with the path included by the compiler. The preprocessor cannot find the header from the source file you are trying to compile.

I think you could fix this by replacing

#include "AwarenessMoment.h"

from

#include "../sensor/AwarenessMoment.h"

Either this, or changing the compiler includes a path to include the sensor directory and use:

#include <AwarenessMoment>

+1
source

Source: https://habr.com/ru/post/1400086/


All Articles