MantisBT - CMake
View Issue Details
0014309CMakeCMakepublic2013-07-24 16:202013-12-02 08:51
jmcm 
Brad King 
normalminoralways
closedfixed 
anyanyany
 
CMake 2.8.12CMake 2.8.12 
0014309: CHECK_C_COMPILER_FLAG does not behave like the manpage states
The manpage states that CHECK_C_COMPILER_FLAG accepts the same flags as CHECK_C_SOURCE_COMPILES, but then it overwrites CMAKE_REQUIRED_DEFINITIONS.

So either the manpage is wrong or the implementation is wrong. I found the bug because I relied on the documented behaviour - I want to have some fixed flags to be passed to all tests.

Workaround (as of now untested): pass the flag to test plus all the fixed flags to
CHECK_C_COMPILER_FLAG
Read the source, Luke (Modules/CheckCCompilerFlag.cmake)
At least versions 2.8.9 and git HEAD.
No tags attached.
Issue History
2013-07-24 16:20jmcmNew Issue
2013-07-25 08:27Brad KingNote Added: 0033602
2013-07-25 08:27Brad KingAssigned To => Brad King
2013-07-25 08:27Brad KingStatusnew => resolved
2013-07-25 08:27Brad KingResolutionopen => fixed
2013-07-25 08:27Brad KingFixed in Version => CMake 2.8.12
2013-07-25 08:27Brad KingTarget Version => CMake 2.8.12
2013-12-02 08:51Robert MaynardNote Added: 0034656
2013-12-02 08:51Robert MaynardStatusresolved => closed

Notes
(0033602)
Brad King   
2013-07-25 08:27   
Documentation updated:

 http://cmake.org/gitweb?p=cmake.git;a=commitdiff;h=3e79d656 [^]
(0034656)
Robert Maynard   
2013-12-02 08:51   
Closing resolved issues that have not been updated in more than 4 months.