[CMake] Eclipse generator - scanner-discovered include pathsand pre-processor symbols

Alexander Neundorf a.neundorf-work at gmx.net
Tue Mar 15 17:27:59 EDT 2011


On Tuesday 15 March 2011, Chatterjee, Shash wrote:
> Hi Alex,
>
> Yes, that is correct, that one pathentry line added to .cproject is all
> that is needed from the generator.  The scanner simply detects the built-in
> symbols and paths and sticks them in the container.  Then, the container
> contribution has to be added as part of the project paths.  Then, the
> indexer can find all the include files, and the pre-processor conditions
> work correctly.
>
> Or, at least, that is my understanding :-).

Ok.
I tried as it is now and also with the additional line.
In both cases I created an Eclipse project for cmake and loaded it in Eclipse.
In both cases Eclipse started building the workspace and the indexer was 
running.
In Both cases Eclipse offered autocompletion e.g. for the cmMakefile class, 
also in both cases a block
#ifdef __FLT_MIN__
was highlighted differently than a block
#ifdef __FLT_MIN__X__ 
(which is not a predefined macro).

Screenshots are here:
http://www.neundorf.net/pics/eclipse-without-patch.jpg
http://www.neundorf.net/pics/eclipse-with-patch.jpg

Which difference should the added line make ?

Alex


More information about the CMake mailing list