[Cmake-commits] CMake branch, next, updated. v3.2.2-2274-g911037d

Brad King brad.king at kitware.com
Wed Apr 29 08:50:20 EDT 2015


This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project "CMake".

The branch, next has been updated
       via  911037db1a137345afc4bebd97f6786bd43f82ad (commit)
       via  6ac3712da0f1e90884a27d9c03974260f42d04f7 (commit)
      from  ed9616928b88eef8d7ea7b7f7e02a994ea8b0e59 (commit)

Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.

- Log -----------------------------------------------------------------
http://cmake.org/gitweb?p=cmake.git;a=commitdiff;h=911037db1a137345afc4bebd97f6786bd43f82ad
commit 911037db1a137345afc4bebd97f6786bd43f82ad
Merge: ed96169 6ac3712
Author:     Brad King <brad.king at kitware.com>
AuthorDate: Wed Apr 29 08:50:19 2015 -0400
Commit:     CMake Topic Stage <kwrobot at kitware.com>
CommitDate: Wed Apr 29 08:50:19 2015 -0400

    Merge topic 'doc-cmake_minimum_required-first' into next
    
    6ac3712d Help: Document that cmake_minimum_required should be called first


http://cmake.org/gitweb?p=cmake.git;a=commitdiff;h=6ac3712da0f1e90884a27d9c03974260f42d04f7
commit 6ac3712da0f1e90884a27d9c03974260f42d04f7
Author:     Brad King <brad.king at kitware.com>
AuthorDate: Wed Apr 29 08:42:10 2015 -0400
Commit:     Brad King <brad.king at kitware.com>
CommitDate: Wed Apr 29 08:49:59 2015 -0400

    Help: Document that cmake_minimum_required should be called first
    
    Many projects put their project() call first, but the actions taken
    by this command can be influenced by policies and other information
    set by a call to cmake_minimum_required.  Document in each of these
    two commands that cmake_minimum_required should be called first.
    
    Suggested-by: Alan W. Irwin

diff --git a/Help/command/cmake_minimum_required.rst b/Help/command/cmake_minimum_required.rst
index 1bdffa4..92e3001 100644
--- a/Help/command/cmake_minimum_required.rst
+++ b/Help/command/cmake_minimum_required.rst
@@ -28,3 +28,10 @@ which enables compatibility features for CMake 2.4 and lower.
 The FATAL_ERROR option is accepted but ignored by CMake 2.6 and
 higher.  It should be specified so CMake versions 2.4 and lower fail
 with an error instead of just a warning.
+
+.. note::
+  Call the ``cmake_minimum_required()`` command at the beginning of
+  the top-level ``CMakeLists.txt`` file even before calling the
+  :command:`project` command.  It is important to establish version
+  and policy settings before invoking other commands whose behavior
+  they may affect.  See also policy :policy:`CMP0000`.
diff --git a/Help/command/project.rst b/Help/command/project.rst
index c601a01..6c5ace7 100644
--- a/Help/command/project.rst
+++ b/Help/command/project.rst
@@ -55,3 +55,10 @@ literal, direct call to the :command:`project` command; loading one
 through the :command:`include` command is not sufficient.  If no such
 call exists CMake will implicitly add one to the top that enables the
 default languages (``C`` and ``CXX``).
+
+.. note::
+  Call the :command:`cmake_minimum_required` command at the beginning
+  of the top-level ``CMakeLists.txt`` file even before calling the
+  ``project()`` command.  It is important to establish version and
+  policy settings before invoking other commands whose behavior they
+  may affect.  See also policy :policy:`CMP0000`.

-----------------------------------------------------------------------

Summary of changes:
 Help/command/cmake_minimum_required.rst |    7 +++++++
 Help/command/project.rst                |    7 +++++++
 2 files changed, 14 insertions(+)


hooks/post-receive
-- 
CMake


More information about the Cmake-commits mailing list