1

I have set up an Eclipse environment (Eclipse IDE for Embedded C/C++ Developers 2022-12) for building C applications for a Raspberry Pi Pico. The Pico SDK uses CMake (cmake version 3.23.2) to create the Eclipse Makefiles.

Everything builds fine, but the C/C++ Editor is showing several symbols, coming from includes, as undefined.

I have been googling solutions, and several suggest changing the properties for include paths, but the suggested property does not exist in my project/workspace. Possible the answer was old, or for a different version of eclipse.

Again, the compile works but the C/C++ Editor marks the symbols as undefined (is that Codan?)

enter image description here

Is there a different include path for the editor syntax checker then the Make system? Where is that defined? Any other ideas?

The project include paths are correctly including the header files: enter image description here

wdtj
  • 4,554
  • 3
  • 17
  • 20
  • Yes, this is Codan. Did you use your natural intelligence (in contrast to artificial intelligence) to find the preferences where to add paths to the used include files? – the busybee Feb 08 '23 at 16:24
  • Since the makefile include paths are correct (no compile/link errors) but the editor paths are not I looked for different path lists. All it shows in both the project and workspace properties is a "C/C++ Include Paths and Symbols". How is the build paths differentiated from the editor syntax checker (Codan) paths. If it is correct for one, shouldn't it be correct for both? In addition, the #include statements are not showing an error, just the symbol itself. – wdtj Feb 08 '23 at 20:05
  • Well, an IDE _is not_ the compiler, especially when cross-compiling. Therefore, successfully compiling (header files found in include paths) and linking (libraries found in library paths) is a different beast than the view of the editor and the code analysis. So, no, it does not be correct for both, if only one is correct. -- Did you try to add the paths? – the busybee Feb 08 '23 at 21:16
  • The paths are there. There is only one path from what I can see, and it works fine for the compiler, but not for the editor. Therefore there is a second set of paths for the editor. I have been all through the properties and all I can find is the one, and it is correct. – wdtj Feb 09 '23 at 15:28
  • I'm using the same version, but have not used it for Raspi development (yet). But my list of project properties looks different, having a page "Paths and Symbols" inside "C/C++ General". In an embedded system's project using a strange cross compiler for the target and MinGW for local tests, I added manually "$(ProjDirPath)/inc/..." as often as necessary to find all header files. -- Anyway, did you try to rebuild the index? – the busybee Feb 10 '23 at 07:44
  • Yes, I tried that to start, and just tried it again. No joy. – wdtj Feb 10 '23 at 14:54
  • This is the everyday Eclipse experience. If you want to do actual programming instead of resolving mysterious linker errors all day, then perhaps consider a better IDE. – Lundin Feb 15 '23 at 12:45

0 Answers0