View Issue Details Jump to Notes ] Print ]
IDProjectCategoryView StatusDate SubmittedLast Update
0005819CMakeCMakepublic2007-10-02 16:202008-02-21 14:21
ReporterPhilip Lowman 
Assigned ToMiguel Figueroa 
PrioritynormalSeverityfeatureReproducibilityalways
StatusclosedResolutionfixed 
PlatformOSOS Version
Product Version 
Target VersionFixed in Version 
Summary0005819: Eclipse CDT4 Generator does not detect preprocessor definitions in use during compilation
DescriptionWhen using Eclipse with a custom makefile project (generated by CMake) it scans preprocessor definitions defined at the command line during compilation and uses them to grey out sections of the code not currently being compiled due to definitions.

For some reason the CDT4 Generator does not do this. All #ifdef parts of the code are greyed out and the autodetection of what variables are being defined and their values is not occuring. This causes problems when trying to do certain things in the grey section like look up definitions.

The following patch fixes the behavior by scanning all of the Makefile's for all preprocessor definitions and tells Eclipse to automatically pick them up from the command line when source files are compiled.

This is a beta patch that hasn't been extensively tested.
TagsNo tags attached.
Attached Filesdiff file icon cmake_eclipse_definitions.diff [^] (3,760 bytes) 2007-10-02 16:21 [Show Content]

 Relationships

  Notes
(0009529)
Alex Neundorf (developer)
2007-10-23 03:38

I think the patch looks good so far (I didn't test it).
It wouldn't hurt to put the added code in a separate method, so the mthods don't get too long.

Alex
(0010621)
Alex Neundorf (developer)
2008-02-21 14:21

I committed the patch from Miguel two days ago or so.
Please test that current cvs works for you, if it doesn't feel free to reopen this bug report.

Alex

 Issue History
Date Modified Username Field Change
2007-10-02 16:20 Philip Lowman New Issue
2007-10-02 16:21 Philip Lowman File Added: cmake_eclipse_definitions.diff
2007-10-02 19:11 Miguel Figueroa Status new => assigned
2007-10-02 19:11 Miguel Figueroa Assigned To => Miguel Figueroa
2007-10-23 03:38 Alex Neundorf Note Added: 0009529
2008-02-21 14:21 Alex Neundorf Note Added: 0010621
2008-02-21 14:21 Alex Neundorf Status assigned => closed
2008-02-21 14:21 Alex Neundorf Resolution open => fixed


Copyright © 2000 - 2018 MantisBT Team