[Cmake-commits] CMake branch, next, updated. v3.5.0-580-ge65e790
Brad King
brad.king at kitware.com
Tue Mar 22 08:01:55 EDT 2016
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 e65e7901dbe6ae06a1817e695ad9bfed04c4c3a1 (commit)
via 9ead71df66ef41e30e75f91d059e16881c942652 (commit)
via e9bf8ec849eb215993bc3883fac061da251d538b (commit)
from a397a637f2989ca89edc2b3b98047b651b5da8ed (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 -----------------------------------------------------------------
https://cmake.org/gitweb?p=cmake.git;a=commitdiff;h=e65e7901dbe6ae06a1817e695ad9bfed04c4c3a1
commit e65e7901dbe6ae06a1817e695ad9bfed04c4c3a1
Merge: a397a63 9ead71d
Author: Brad King <brad.king at kitware.com>
AuthorDate: Tue Mar 22 08:01:54 2016 -0400
Commit: CMake Topic Stage <kwrobot at kitware.com>
CommitDate: Tue Mar 22 08:01:54 2016 -0400
Merge topic 'ninja-directory-targets' into next
9ead71df Help: Add notes for topic 'ninja-directory-targets'
e9bf8ec8 Ninja: Add test for `$subdir/all` targets
https://cmake.org/gitweb?p=cmake.git;a=commitdiff;h=9ead71df66ef41e30e75f91d059e16881c942652
commit 9ead71df66ef41e30e75f91d059e16881c942652
Author: Brad King <brad.king at kitware.com>
AuthorDate: Fri Mar 18 10:52:46 2016 -0400
Commit: Brad King <brad.king at kitware.com>
CommitDate: Tue Mar 22 08:01:14 2016 -0400
Help: Add notes for topic 'ninja-directory-targets'
diff --git a/Help/release/dev/ninja-directory-targets.rst b/Help/release/dev/ninja-directory-targets.rst
new file mode 100644
index 0000000..4826228
--- /dev/null
+++ b/Help/release/dev/ninja-directory-targets.rst
@@ -0,0 +1,7 @@
+ninja-directory-targets
+-----------------------
+
+* The :generator:`Ninja` generator learned to produce phony targets
+ of the form ``sub/dir/all`` to drive the build of a subdirectory.
+ This is equivalent to ``cd sub/dir; make all`` with
+ :ref:`Makefile Generators`.
https://cmake.org/gitweb?p=cmake.git;a=commitdiff;h=e9bf8ec849eb215993bc3883fac061da251d538b
commit e9bf8ec849eb215993bc3883fac061da251d538b
Author: Brad King <brad.king at kitware.com>
AuthorDate: Fri Mar 18 10:52:37 2016 -0400
Commit: Brad King <brad.king at kitware.com>
CommitDate: Tue Mar 22 08:01:14 2016 -0400
Ninja: Add test for `$subdir/all` targets
diff --git a/Tests/RunCMake/Ninja/RunCMakeTest.cmake b/Tests/RunCMake/Ninja/RunCMakeTest.cmake
index 64f97bc..4e06888 100644
--- a/Tests/RunCMake/Ninja/RunCMakeTest.cmake
+++ b/Tests/RunCMake/Ninja/RunCMakeTest.cmake
@@ -16,3 +16,19 @@ run_CMP0058(WARN-no)
run_CMP0058(WARN-by)
run_CMP0058(NEW-no)
run_CMP0058(NEW-by)
+
+function(run_SubDir)
+ # Use a single build tree for a few tests without cleaning.
+ set(RunCMake_TEST_BINARY_DIR ${RunCMake_BINARY_DIR}/SubDir-build)
+ set(RunCMake_TEST_NO_CLEAN 1)
+ file(REMOVE_RECURSE "${RunCMake_TEST_BINARY_DIR}")
+ file(MAKE_DIRECTORY "${RunCMake_TEST_BINARY_DIR}")
+ run_cmake(SubDir)
+ if(WIN32)
+ set(SubDir_all [[SubDir\all]])
+ else()
+ set(SubDir_all [[SubDir/all]])
+ endif()
+ run_cmake_command(SubDir-build ${CMAKE_COMMAND} --build . --target ${SubDir_all})
+endfunction()
+run_SubDir()
diff --git a/Tests/RunCMake/Ninja/SubDir-build-stdout.txt b/Tests/RunCMake/Ninja/SubDir-build-stdout.txt
new file mode 100644
index 0000000..e4b4662
--- /dev/null
+++ b/Tests/RunCMake/Ninja/SubDir-build-stdout.txt
@@ -0,0 +1 @@
+Building InAll
diff --git a/Tests/RunCMake/Ninja/SubDir.cmake b/Tests/RunCMake/Ninja/SubDir.cmake
new file mode 100644
index 0000000..7224ec3
--- /dev/null
+++ b/Tests/RunCMake/Ninja/SubDir.cmake
@@ -0,0 +1,2 @@
+add_subdirectory(SubDir)
+add_custom_target(TopFail ALL COMMAND does_not_exist)
diff --git a/Tests/RunCMake/Ninja/SubDir/CMakeLists.txt b/Tests/RunCMake/Ninja/SubDir/CMakeLists.txt
new file mode 100644
index 0000000..73ae431
--- /dev/null
+++ b/Tests/RunCMake/Ninja/SubDir/CMakeLists.txt
@@ -0,0 +1,2 @@
+add_custom_target(SubFail COMMAND does_not_exist)
+add_custom_target(InAll ALL COMMAND ${CMAKE_COMMAND} -E echo "Building InAll")
-----------------------------------------------------------------------
Summary of changes:
hooks/post-receive
--
CMake
More information about the Cmake-commits
mailing list