|External #define -> indexer [message #989848]
||Sat, 08 December 2012 12:55
| Martin CS
Registered: December 2012
In my project we are using a custom configuration system (in its own modularized non-C language) that is parsed before, and creates the configuration for, the build of C (etc.). One of the aspects of this is that it passes #defines to the C-build process, which thus are not available prior to the parsing of the configuration and influences the C-code used.
This means that the indexer will not work correctly, since it is lacking information (the external defines). You could basically view it as a set of per-file -D passed on the command line to the compiler.
An intermediate step is that the parsed per-file -D are all put inside a standard makefile. This is created by the "build" (parsing) of the configuration prior to starting the C-build which depends on the configuration.
I would like to create a solution that correctly handles the indexing and thus if anyone could give me a few pointers on where to look or even sketch out how and what to hook in where, I will highly appreciate it.
I see two possibilities:
1) base it on the makefile
2) full fledged parser of custom configuration and hooking it into CDT
The first one is easier and would just require an initial invocation of the first step in the build process, but it will not be able to adapt automatically to changes in the configuration code itself during editing.
The second one is cooler.
I have no idea where to begin with any of these two options. I have never developed for Eclipse before, but I do develop with Eclipse every day.
Also if you know of any similar efforts, projects or threads then please do tell me!
Powered by FUDForum
. Page generated in 0.05570 seconds