[cmake-developers] RFC: add version to project() call
Brad King
brad.king at kitware.com
Wed Jan 29 11:12:27 EST 2014
On 01/29/2014 10:33 AM, Matthew Woehlke wrote:
> Can one use project(VERSION) and later set the policy to OLD to get the
> old, don't-unset-the-variables behavior from that point onwards?
Yes. A subproject that has not been updated to understand the
policy would normally run cmake_minimum_required with a version
old enough to unset the policy and get the old behavior (with
a warning).
However, a policy is not a switch between two desirable behaviors.
It should never be set to OLD explicitly in new code. The only
time a policy should be set to OLD is in a maintenance branch of
an existing project release just to silence the policy warning.
-Brad
More information about the cmake-developers
mailing list