MantisBT - CMake
View Issue Details
0012551CMakeCMakepublic2011-11-02 08:092011-12-16 17:23
Paul Gideon Dann 
Alex Neundorf 
normalmajoralways
closedfixed 
x86_64ArchLinux
CMake 2.8.6 
CMake 2.8.7CMake 2.8.7 
0012551: New CMAKE_AUTOMOC feature breaks when re-configuring
When re-configuring & generating with ccmake, the automoc build.cmake file adds a leading slash to the "cmake" command, causing it to break.

Follow the steps below using the testcase provided to reproduce the bug.
* Create "build" directory and run "cmake .." inside.
* Note that running "make" at this point yields a good compile.
* Start again with a clean directory, but instead of building, run "ccmake .."
* Configure & Generate
* Try to build again

You'll get a "/cmake: Command not found" error. This is caused by a leading slash that has been introduced in CMakeFiles/example_automoc.dir/build.make (line 48), in the CMakeFiles/example_automoc rule. Removing the slash from "/cmake" fixes the problem, and the testcase builds correctly.
No tags attached.
bz2 testcase.tar.bz2 (784) 2011-11-02 08:09
https://public.kitware.com/Bug/file/4105/testcase.tar.bz2
Issue History
2011-11-02 08:09Paul Gideon DannNew Issue
2011-11-02 08:09Paul Gideon DannFile Added: testcase.tar.bz2
2011-11-02 08:33Brad KingAssigned To => Alex Neundorf
2011-11-02 08:33Brad KingStatusnew => assigned
2011-11-03 18:04Alex NeundorfNote Added: 0027720
2011-11-03 18:04Alex NeundorfStatusassigned => closed
2011-11-03 18:04Alex NeundorfResolutionopen => fixed
2011-12-16 17:23David ColeFixed in Version => CMake 2.8.7
2011-12-16 17:23David ColeTarget Version => CMake 2.8.7

Notes
(0027720)
Alex Neundorf   
2011-11-03 18:04   
cmake::GetCMakeCommand() returned a wrong path when called from ccmake, if ccmake has been started via the PATH.
Fixed and merged into next. Should be in 2.8.7.