MantisBT - CMake
View Issue Details
0014571CMakeCMakepublic2013-11-15 08:192016-06-10 14:31
Magnus Johansson 
Kitware Robot 
normalminorrandom
closedmoved 
CMake 2.8.11.1 
 
0014571: CMake does not validate cache entries given on the command line
Typically you set a cache entry like this:

cmake -DMYFLAG:string=ON

However, cmake also accepts this degenerate case:

cmake -D:string=ON

When called like this I got very strange build failures:

[ 32%] Building C object progs/bkz/prog/CMakeFiles/bkz.dir/bkz.c.o
cd /import/build/magnus/rembuild/boks/redhat-6.0/progs/bkz/prog && /usr/bin/cc -I/import/build/magnus/rembuild/boks/redhat-6.0/BUILD/include -o CMakeFiles/bkz.dir/bkz.c.o -c /import/build/mj/boks-sources/boks/progs/bkz/prog/bkz.c
Linking C executable ONbkz

Note that when linking, bkz had received the prefix "ON" which shouldn't be there, and caused subsequent errors.

(CMake got called with bad input like this due to a bug in our build scripts, where a variable was sometimes not set. This was very hard to track down. If CMake had validated the input, this would have been much easier to find.)
No tags attached.
Issue History
2013-11-15 08:19Magnus JohanssonNew Issue
2016-06-10 14:29Kitware RobotNote Added: 0042425
2016-06-10 14:29Kitware RobotStatusnew => resolved
2016-06-10 14:29Kitware RobotResolutionopen => moved
2016-06-10 14:29Kitware RobotAssigned To => Kitware Robot
2016-06-10 14:31Kitware RobotStatusresolved => closed

Notes
(0042425)
Kitware Robot   
2016-06-10 14:29   
Resolving issue as `moved`.

This issue tracker is no longer used. Further discussion of this issue may take place in the current CMake Issues page linked in the banner at the top of this page.