Reputation: 1084
I have a project which use gcc -include file.h
As gcc documentation say, this ensures that file.h is included in every file which is compiled this way (meaning like there was #include "file.h" in every other files).
Now I have imported this project into eclipse and I set up the include path where that file is but can't figure out how to do something like gcc -include in eclipse project setting. The result of this is that in editor I have a LOT of "Symbol xy could not be resolved" but the project compiles just fine.
Thanks for any help.
Upvotes: 5
Views: 1408
Reputation: 28659
You can change the CDT GCC Built-in Compiler Settings
on a project-by-project basis.
Project
-> Properties
-> C/C++ General
-> Preprocessor Include Paths, Macros etc.
Providers
tab.CDT GCC Built-in Compiler Settings
Use global provider shared between projects
Command to get compiler specs:
input box(see highlighted text in image below)
You probably want to click Store entries in project settings folder
Upvotes: 2