[Cmake-commits] CMake branch, next, updated. v3.1.0-rc3-1209-gd43b20f

Brad King brad.king at kitware.com
Wed Dec 17 11:18:00 EST 2014


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  d43b20fb1b6c136548bd60acb74df1cc71d3a8fc (commit)
       via  eeaa25e52144626dc76717dea37af3b8d20cb171 (commit)
      from  12c11218568d9e2b9b40198813a058ed577b5577 (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=d43b20fb1b6c136548bd60acb74df1cc71d3a8fc
commit d43b20fb1b6c136548bd60acb74df1cc71d3a8fc
Merge: 12c1121 eeaa25e
Author:     Brad King <brad.king at kitware.com>
AuthorDate: Wed Dec 17 11:17:58 2014 -0500
Commit:     CMake Topic Stage <kwrobot at kitware.com>
CommitDate: Wed Dec 17 11:17:58 2014 -0500

    Merge topic 'vs-nsight-tegra-min-api' into next
    
    eeaa25e5 Add 'ANDROID_API_MIN' target property to set Android Target MIN API


http://cmake.org/gitweb?p=cmake.git;a=commitdiff;h=eeaa25e52144626dc76717dea37af3b8d20cb171
commit eeaa25e52144626dc76717dea37af3b8d20cb171
Author:     Dmitry Polyanitsa <dpolyanitsa at nvidia.com>
AuthorDate: Wed Dec 17 17:11:51 2014 +0300
Commit:     Brad King <brad.king at kitware.com>
CommitDate: Wed Dec 17 11:17:28 2014 -0500

    Add 'ANDROID_API_MIN' target property to set Android Target MIN API
    
    Also add a 'CMAKE_ANDROID_API_MIN' variable to set the property
    default.  Teach the VS generator to write the MIN API value into
    Nsight Tegra project files.

diff --git a/Help/manual/cmake-properties.7.rst b/Help/manual/cmake-properties.7.rst
index cca6d28..68954c5 100644
--- a/Help/manual/cmake-properties.7.rst
+++ b/Help/manual/cmake-properties.7.rst
@@ -80,6 +80,7 @@ Properties on Targets
 
    /prop_tgt/ALIASED_TARGET
    /prop_tgt/ANDROID_API
+   /prop_tgt/ANDROID_API_MIN
    /prop_tgt/ANDROID_GUI
    /prop_tgt/ARCHIVE_OUTPUT_DIRECTORY_CONFIG
    /prop_tgt/ARCHIVE_OUTPUT_DIRECTORY
diff --git a/Help/manual/cmake-toolchains.7.rst b/Help/manual/cmake-toolchains.7.rst
index 44ffb3b..054438d 100644
--- a/Help/manual/cmake-toolchains.7.rst
+++ b/Help/manual/cmake-toolchains.7.rst
@@ -256,5 +256,6 @@ like this:
 The :variable:`CMAKE_GENERATOR_TOOLSET` may be set to select
 the Nsight Tegra "Toolchain Version" value.
 
-See the :prop_tgt:`ANDROID_API` and :prop_tgt:`ANDROID_GUI`
-target properties to configure targets within the project.
+See the :prop_tgt:`ANDROID_API_MIN`, :prop_tgt:`ANDROID_API`
+and :prop_tgt:`ANDROID_GUI` target properties to configure
+targets within the project.
diff --git a/Help/manual/cmake-variables.7.rst b/Help/manual/cmake-variables.7.rst
index 2de4103..4d54075 100644
--- a/Help/manual/cmake-variables.7.rst
+++ b/Help/manual/cmake-variables.7.rst
@@ -206,6 +206,7 @@ Variables that Control the Build
    :maxdepth: 1
 
    /variable/CMAKE_ANDROID_API
+   /variable/CMAKE_ANDROID_API_MIN
    /variable/CMAKE_ANDROID_GUI
    /variable/CMAKE_ARCHIVE_OUTPUT_DIRECTORY
    /variable/CMAKE_AUTOMOC_MOC_OPTIONS
diff --git a/Help/prop_tgt/ANDROID_API_MIN.rst b/Help/prop_tgt/ANDROID_API_MIN.rst
new file mode 100644
index 0000000..773ab3f
--- /dev/null
+++ b/Help/prop_tgt/ANDROID_API_MIN.rst
@@ -0,0 +1,7 @@
+ANDROID_API_MIN
+---------------
+
+Set the Android MIN API version (e.g. ``9``).  The version number
+must be a positive decimal integer.  This property is initialized by
+the value of the :variable:`CMAKE_ANDROID_API_MIN` variable if it is set
+when a target is created.  Native code builds using this API version.
diff --git a/Help/release/dev/vs-nsight-tegra-min-api.rst b/Help/release/dev/vs-nsight-tegra-min-api.rst
new file mode 100644
index 0000000..f8fa056
--- /dev/null
+++ b/Help/release/dev/vs-nsight-tegra-min-api.rst
@@ -0,0 +1,5 @@
+vs-nsight-tegra-min-api
+-----------------------
+
+* A :prop_tgt:`ANDROID_API_MIN` target property was introduced to
+  specify the minimum version to be targeted by the toolchain.
diff --git a/Help/variable/CMAKE_ANDROID_API_MIN.rst b/Help/variable/CMAKE_ANDROID_API_MIN.rst
new file mode 100644
index 0000000..0246c75
--- /dev/null
+++ b/Help/variable/CMAKE_ANDROID_API_MIN.rst
@@ -0,0 +1,5 @@
+CMAKE_ANDROID_API_MIN
+---------------------
+
+Default value for the :prop_tgt:`ANDROID_API_MIN` target property.
+See that target property for additional information.
diff --git a/Source/cmTarget.cxx b/Source/cmTarget.cxx
index 37aa26e..865a824 100644
--- a/Source/cmTarget.cxx
+++ b/Source/cmTarget.cxx
@@ -325,6 +325,7 @@ void cmTarget::SetMakefile(cmMakefile* mf)
   if (this->GetType() != INTERFACE_LIBRARY && this->GetType() != UTILITY)
     {
     this->SetPropertyDefault("ANDROID_API", 0);
+    this->SetPropertyDefault("ANDROID_API_MIN", 0);
     this->SetPropertyDefault("INSTALL_NAME_DIR", 0);
     this->SetPropertyDefault("INSTALL_RPATH", "");
     this->SetPropertyDefault("INSTALL_RPATH_USE_LINK_PATH", "OFF");
diff --git a/Source/cmVisualStudio10TargetGenerator.cxx b/Source/cmVisualStudio10TargetGenerator.cxx
index f903bdb..b265c0e 100644
--- a/Source/cmVisualStudio10TargetGenerator.cxx
+++ b/Source/cmVisualStudio10TargetGenerator.cxx
@@ -748,6 +748,12 @@ void cmVisualStudio10TargetGenerator
   ntv += toolset? toolset : "Default";
   ntv += "</NdkToolchainVersion>\n";
   this->WriteString(ntv.c_str(), 2);
+  if(const char* minApi = this->Target->GetProperty("ANDROID_API_MIN"))
+    {
+    this->WriteString("<AndroidMinAPI>", 2);
+    (*this->BuildFileStream ) <<
+      "android-" << cmVS10EscapeXML(minApi) << "</AndroidMinAPI>\n";
+    }
   if(const char* api = this->Target->GetProperty("ANDROID_API"))
     {
     this->WriteString("<AndroidTargetAPI>", 2);
diff --git a/Tests/VSNsightTegra/CMakeLists.txt b/Tests/VSNsightTegra/CMakeLists.txt
index 570733b..10f55d9 100644
--- a/Tests/VSNsightTegra/CMakeLists.txt
+++ b/Tests/VSNsightTegra/CMakeLists.txt
@@ -1,6 +1,7 @@
 cmake_minimum_required(VERSION 3.0)
 project(VSNsightTegra C CXX)
 
+set(CMAKE_ANDROID_API_MIN 9)
 set(CMAKE_ANDROID_API 15)
 set(CMAKE_ANDROID_GUI 1)
 

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

Summary of changes:
 Help/manual/cmake-properties.7.rst           |    1 +
 Help/manual/cmake-toolchains.7.rst           |    5 +++--
 Help/manual/cmake-variables.7.rst            |    1 +
 Help/prop_tgt/ANDROID_API_MIN.rst            |    7 +++++++
 Help/release/dev/vs-nsight-tegra-min-api.rst |    5 +++++
 Help/variable/CMAKE_ANDROID_API_MIN.rst      |    5 +++++
 Source/cmTarget.cxx                          |    1 +
 Source/cmVisualStudio10TargetGenerator.cxx   |    6 ++++++
 Tests/VSNsightTegra/CMakeLists.txt           |    1 +
 9 files changed, 30 insertions(+), 2 deletions(-)
 create mode 100644 Help/prop_tgt/ANDROID_API_MIN.rst
 create mode 100644 Help/release/dev/vs-nsight-tegra-min-api.rst
 create mode 100644 Help/variable/CMAKE_ANDROID_API_MIN.rst


hooks/post-receive
-- 
CMake


More information about the Cmake-commits mailing list