[Cmake-commits] CMake branch, next, updated. v3.0.0-rc1-1177-g3907dd1

Stephen Kelly steveire at gmail.com
Tue Mar 18 15:41:39 EDT 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  3907dd1e368a79bf383bad4a549e7c56faa4076e (commit)
       via  38c877e1d7be3cb8ded870394effa39ef1e06286 (commit)
      from  9eea0f217f202fdc8ea7169a5d2504b248db70fb (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=3907dd1e368a79bf383bad4a549e7c56faa4076e
commit 3907dd1e368a79bf383bad4a549e7c56faa4076e
Merge: 9eea0f2 38c877e
Author:     Stephen Kelly <steveire at gmail.com>
AuthorDate: Tue Mar 18 15:41:38 2014 -0400
Commit:     CMake Topic Stage <kwrobot at kitware.com>
CommitDate: Tue Mar 18 15:41:38 2014 -0400

    Merge topic 'target-sources-refactor' into next
    
    38c877e1 Config-specific tests.


http://cmake.org/gitweb?p=cmake.git;a=commitdiff;h=38c877e1d7be3cb8ded870394effa39ef1e06286
commit 38c877e1d7be3cb8ded870394effa39ef1e06286
Author:     Stephen Kelly <steveire at gmail.com>
AuthorDate: Tue Mar 18 20:34:09 2014 +0100
Commit:     Stephen Kelly <steveire at gmail.com>
CommitDate: Tue Mar 18 20:40:24 2014 +0100

    Config-specific tests.

diff --git a/Tests/GeneratorExpression/CMakeLists.txt b/Tests/GeneratorExpression/CMakeLists.txt
index b76cb33..b506853 100644
--- a/Tests/GeneratorExpression/CMakeLists.txt
+++ b/Tests/GeneratorExpression/CMakeLists.txt
@@ -267,6 +267,7 @@ file(GENERATE
 add_custom_target(check_object_files ALL
   COMMAND ${CMAKE_COMMAND}
     "-DOBJLIB_LISTFILE=${CMAKE_CURRENT_BINARY_DIR}/objlib_files"
+    -DTEST_CONFIGURATION=${CMAKE_BUILD_TYPE}
     -DEXPECTED_NUM_OBJECTFILES=2
     -P "${CMAKE_CURRENT_SOURCE_DIR}/check_object_files.cmake"
   DEPENDS objlib
diff --git a/Tests/GeneratorExpression/check_object_files.cmake b/Tests/GeneratorExpression/check_object_files.cmake
index 6e5ff43..f8fcf42 100644
--- a/Tests/GeneratorExpression/check_object_files.cmake
+++ b/Tests/GeneratorExpression/check_object_files.cmake
@@ -11,7 +11,21 @@ if (NOT EXPECTED_NUM_OBJECTFILES EQUAL num_objectfiles)
 endif()
 
 foreach(objlib_file ${objlib_files})
-  if (NOT EXISTS ${objlib_file})
+  set(file_exists False)
+  if (EXISTS ${objlib_file})
+    set(file_exists True)
+  endif()
+
+  if (NOT file_exists)
+    foreach(config_macro "$(Configuration)" "$(OutDir)" "$(IntDir)")
+      string(REPLACE "${config_macro}" "${TEST_CONFIGURATION}" config_file "${objlib_file}")
+      if (EXISTS ${config_file})
+        set(file_exists True)
+      endif()
+    endforeach()
+  endif()
+
+  if (NOT file_exists)
     message(SEND_ERROR "File \"${objlib_file}\" does not exist!")
   endif()
 endforeach()

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

Summary of changes:
 Tests/GeneratorExpression/CMakeLists.txt           |    1 +
 Tests/GeneratorExpression/check_object_files.cmake |   16 +++++++++++++++-
 2 files changed, 16 insertions(+), 1 deletion(-)


hooks/post-receive
-- 
CMake


More information about the Cmake-commits mailing list