cancel
Showing results for 
Search instead for 
Did you mean: 

CubeIDE: No such file or directory, but file is part of include path

KMew
Senior III

Hello,

I fear I may be getting tunnel visioned, but I am getting an error when I try to manually add the BSP files for the STM32H7B3I-EVAL board.

I am getting the following error: "Description Resource Path Location Type

fatal error: stm32h7b3i_eval.h: No such file or directory main.h /Display_CubeMXBringUp_Test/Core/Inc line 34 C/C++ Problem"

Now, the file is in the folder Drivers/BSP/STM32H7B3I-EVAL, which is part of my include path. See the picture below, including the file in the directory via the File Explorer.

Can someone help me figure out what I am doing wrong?

0693W00000WJmO2QAL.png 

0693W00000WJmP0QAL.png 

0693W00000WJmPFQA1.png

1 ACCEPTED SOLUTION

Accepted Solutions
Bob S
Principal

So main.h is trying to include the stm32h7b3i_eval.h file. Look at the console output and see what file was including main.h when it failed. My bet is that it was a cpp file and you didn't update the "include paths" for the C++ compiler.

View solution in original post

3 REPLIES 3
Bob S
Principal

So main.h is trying to include the stm32h7b3i_eval.h file. Look at the console output and see what file was including main.h when it failed. My bet is that it was a cpp file and you didn't update the "include paths" for the C++ compiler.

Hello Bob,

That was precisely what it was! I added it in the GCC Compiler, but not the G++ Compiler. Once I added it to both, the error went away. Thank you!

Can you help me rectify more on what to be done. Am new to STM32CubeIDE, and i get this error

../Src/main.c:53:10: fatal error: BSP_SDRAM.h: No such file or directory

53 | #include "BSP_SDRAM.h"

| ^~~~~~~~~~~~~

compilation terminated.

make: *** [Src/subdir.mk:55: Src/main.o] Error 1

make: *** Waiting for unfinished jobs....

"make -j4 all" terminated with exit code 2. Build might be incomplete.