View Issue Details [ Jump to Notes ] | [ Print ] | ||||||||
ID | Project | Category | View Status | Date Submitted | Last Update | ||||
0016069 | CMake | CMake | public | 2016-04-16 03:49 | 2016-06-10 14:21 | ||||
Reporter | Craig Scott | ||||||||
Assigned To | |||||||||
Priority | normal | Severity | minor | Reproducibility | always | ||||
Status | closed | Resolution | no change required | ||||||
Platform | Apple | OS | OSX | OS Version | 10.10 | ||||
Product Version | CMake 3.5.2 | ||||||||
Target Version | Fixed in Version | ||||||||
Summary | 0016069: Behaviour does not match documentation for policy CMP0048 | ||||||||
Description | The policy documentation for CMP0048 says this: "This policy was introduced in CMake version 3.0. CMake version 3.5.2 warns when the policy is not set and uses OLD behavior. Use the cmake_policy command to set it to OLD or NEW explicitly." In my testing, however, no such warning is issued and the default appears to be NEW, not OLD. | ||||||||
Steps To Reproduce | The following minimal CMakeLists.txt demonstrates the problem: cmake_minimum_required(VERSION 3.5.2) cmake_policy(GET CMP0048 isOn) message("isOn = ${isOn}") project(proj VERSION 1.2.3) Changing the minimum required version doesn't seem to make any difference. | ||||||||
Additional Information | If you explicitly set the policy for CMP0048 to OLD, then the expected error does occur when the project() command includes a VERSION specification. | ||||||||
Tags | No tags attached. | ||||||||
Attached Files | |||||||||
Relationships | |
Relationships |
Notes | |
(0040879) Brad King (manager) 2016-04-18 08:28 |
The call to cmake_minimum_required(VERSION): https://cmake.org/cmake/help/v3.5/command/cmake_minimum_required.html [^] implies a call to cmake_policy(VERSION) which sets the policy to NEW because the min req version specified is at least 3.0. Once the policy is set the NEW behavior is used without any warning. |
(0040880) Brad King (manager) 2016-04-18 08:29 |
For reference, this behavior of cmake_minimum_required has been clarified in post-3.5 documentation updates: Help: Organize and clarify `cmake_minimum_required` documentation https://cmake.org/gitweb?p=cmake.git;a=commitdiff;h=1dc8486b [^] |
(0041190) Kitware Robot (administrator) 2016-06-10 14:21 |
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. |
Notes |
Issue History | |||
Date Modified | Username | Field | Change |
2016-04-16 03:49 | Craig Scott | New Issue | |
2016-04-18 08:28 | Brad King | Note Added: 0040879 | |
2016-04-18 08:28 | Brad King | Status | new => resolved |
2016-04-18 08:28 | Brad King | Resolution | open => no change required |
2016-04-18 08:29 | Brad King | Note Added: 0040880 | |
2016-06-10 14:21 | Kitware Robot | Note Added: 0041190 | |
2016-06-10 14:21 | Kitware Robot | Status | resolved => closed |
Issue History |
Copyright © 2000 - 2018 MantisBT Team |