MantisBT - CMake
View Issue Details
0004308CMakeCMakepublic2007-01-12 18:492016-06-10 14:30
Pierre 
Brad King 
lowmajoralways
closedmoved 
 
 
0004308: passing "0" or zero (0) configure_file as value is not possible
[using 2.4.6]
configure_file uses the 0==off 1==on rule to decide whether or not a line should be commented. See the example below.

Using "0 " "0x0" or 0x0 work (making this issue only an aesthetic problem :)

Example:
SET(GD_VERSION_MAJOR "2")
SET(GD_VERSION_MINOR "0")
SET(GD_VERSION_PATCH "34")
configure_file(config.h.cmake test.h)
----------config.h.cmake
#cmakedefine GD_VERSION_MAJOR ${GD_VERSION_MAJOR}
#cmakedefine GD_VERSION_MINOR ${GD_VERSION_MINOR}
#cmakedefine GD_VERSION_PATCH ${GD_VERSION_PATCH}

---------- test.h
#define GD_VERSION_MAJOR 2
/* #undef GD_VERSION_MINOR 0 */
#define GD_VERSION_PATCH 34
No tags attached.
Issue History
2012-08-13 10:44Brad KingStatusassigned => backlog
2012-08-13 10:44Brad KingNote Added: 0030564
2016-06-10 14:27Kitware RobotNote Added: 0041341
2016-06-10 14:27Kitware RobotStatusbacklog => resolved
2016-06-10 14:27Kitware RobotResolutionopen => moved
2016-06-10 14:30Kitware RobotStatusresolved => closed

Notes
(0030564)
Brad King   
2012-08-13 10:44   
Sending issues I'm not actively working on to the backlog to await someone with time for them.

If an issue you care about is sent to the backlog when you feel it should have been addressed in a different manner, please bring it up on the CMake mailing list for discussion. Sign up for the mailing list here, if you're not already on it:

 http://www.cmake.org/mailman/listinfo/cmake [^]

It's easy to re-activate a bug here if you can find a CMake developer or contributor who has the bandwidth to take it on.
(0041341)
Kitware Robot   
2016-06-10 14:27   
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.