MantisBT - CMake
View Issue Details
0009968CMakeCMakepublic2009-11-25 04:192010-12-12 11:16
Peter Kluger 
Alex Neundorf 
normalminoralways
closedfixed 
CMake-2-8 
CMake 2.8.4 
0009968: Eclipse CDT Project File overwritten by '-G "Eclipse CDT4 - Unix Makefiles"'
I recently start using eclipse in our project and am very happy how it
works with the CMake Eclipse CDT 4.0 generator.
Unfortunately, every time i recall cmake it writes the .project
(+.cproject) file for eclipse and overwrites my personal settings within
that file prior set, like when i set extra make parameters (gmake -j 10 -k).
1. Using the Wikipage http://www.cmake.org/Wiki/CMake:Eclipse_UNIX_Tutorial [^] "Option 0000002" also solves the problem for now, but it would be a good feature if the
'cmake -G "Eclipse CDT4..." ..'
could offer this function instead of calling
'cmake -G "UNIX Makefile" ..'

2. After the response of Alex Neundorf (a.neundorf-work@gmx.net) from the mailing-list, who suggested to report this to the bug-tracker, i am now doing so.
No tags attached.
related to 0009930closed Alex Neundorf Eclipse generator: enable parallel builds ? 
diff cmake-eclipse-make-flags.diff (1,033) 2010-01-30 18:57
https://public.kitware.com/Bug/file/2826/cmake-eclipse-make-flags.diff
Issue History
2009-11-25 04:19Peter KlugerNew Issue
2009-11-25 08:18Bill HoffmanStatusnew => assigned
2009-11-25 08:18Bill HoffmanAssigned To => Alex Neundorf
2009-11-25 13:23Alex NeundorfAssigned ToAlex Neundorf => Miguel Figueroa
2010-01-30 18:56Artyom SmirnovNote Added: 0019372
2010-01-30 18:57Artyom SmirnovFile Added: cmake-eclipse-make-flags.diff
2010-11-10 13:09David ColeTarget Version => CMake 2.8.4
2010-12-08 16:07David ColeRelationship addedrelated to 0009930
2010-12-08 16:08David ColeNote Added: 0023820
2010-12-08 16:08David ColeStatusassigned => closed
2010-12-08 16:08David ColeResolutionopen => won't fix
2010-12-12 11:16Alex NeundorfAssigned ToMiguel Figueroa => Alex Neundorf
2010-12-12 11:16Alex NeundorfNote Added: 0023904
2010-12-12 11:16Alex NeundorfStatusclosed => feedback
2010-12-12 11:16Alex NeundorfResolutionwon't fix => reopened
2010-12-12 11:16Alex NeundorfStatusfeedback => closed
2010-12-12 11:16Alex NeundorfResolutionreopened => fixed

Notes
(0019372)
Artyom Smirnov   
2010-01-30 18:56   
I am suffering with this problem too. CMake resets all my make flags in eclipse project after changes in build scripts. For myself I made a small patch that adds the argument CMAKE_ECLIPSE_MAKE_FLAGS and substitutes its value in org.eclipse.cdt.make.core.build.target.inc. How about adding something to cmake? Also may be other IDE's parameters can be added to cmake generator, and other IDEs like VS and XCode need something like this too.
(0023820)
David Cole   
2010-12-08 16:08   
Closed at the CMake 2.8.4 bug triage meeting, Dec. 8, 2010.

Partially addressed instead when related issue 9930 is fixed.
(0023904)
Alex Neundorf   
2010-12-12 11:16   
See 0009930.
This is now in the next branch on staging and should go into 2.8.4.
There is now a cmake cache variable CMAKE_ECLIPSE_MAKE_ARGUMENTS. So, run cmake and let it generate the Eclipse project, then run make edit_cache or cmake-gui, and enter the make arguments you want (e.g. "-j10 -k") in CMAKE_ECLIPSE_MAKE_ARGUMENTS.
This should do what you want.

Alex