[Cmake-commits] CMake branch, next, updated. v2.8.3-1108-gb44a0b6

David Cole david.cole at kitware.com
Tue Dec 28 11:56:09 EST 2010


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  b44a0b6b2c5e1ee9d2f144a4c0f68fadd250811c (commit)
       via  81136214f3a45c84686461eab3917b6e1115f771 (commit)
       via  73485615b2d66123b4952118440612d4f7bc9d0a (commit)
      from  f106a8f529319a08451bf4abc84903be528a119f (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=b44a0b6b2c5e1ee9d2f144a4c0f68fadd250811c
commit b44a0b6b2c5e1ee9d2f144a4c0f68fadd250811c
Merge: f106a8f 8113621
Author:     David Cole <david.cole at kitware.com>
AuthorDate: Tue Dec 28 11:55:50 2010 -0500
Commit:     CMake Topic Stage <kwrobot at kitware.com>
CommitDate: Tue Dec 28 11:55:50 2010 -0500

    Merge topic 'add-trilinos-contract-test' into next
    
    8113621 Establish pass criteria for the Trilinos contract test.
    7348561 Use m prefix in shorttag value to indicate "md5 of tarball"


http://cmake.org/gitweb?p=cmake.git;a=commitdiff;h=81136214f3a45c84686461eab3917b6e1115f771
commit 81136214f3a45c84686461eab3917b6e1115f771
Author:     David Cole <david.cole at kitware.com>
AuthorDate: Tue Dec 28 11:27:56 2010 -0500
Commit:     David Cole <david.cole at kitware.com>
CommitDate: Tue Dec 28 11:27:56 2010 -0500

    Establish pass criteria for the Trilinos contract test.
    
    Add a ValidateBuild.cmake script that runs after the Trilinos
    dashboard run is complete. In that script, look for some expected
    Trilinos executable files. Run the basic Teuchos unit tests
    executable and expect it to return 0 for no errors.
    
    Also, patch the main CMakeLists.txt file to get rid of new warnings
    from CMake when variables passed in on the command line go
    un-referenced in the CMakeLists processing.

diff --git a/Tests/Contracts/Trilinos-10-6/CMakeLists.txt b/Tests/Contracts/Trilinos-10-6/CMakeLists.txt
index 3e06d4f..79ed669 100644
--- a/Tests/Contracts/Trilinos-10-6/CMakeLists.txt
+++ b/Tests/Contracts/Trilinos-10-6/CMakeLists.txt
@@ -61,6 +61,11 @@ configure_file(
   "${script_dir}/Dashboard.cmake"
   @ONLY)
 
+configure_file(
+  "${CMAKE_CURRENT_SOURCE_DIR}/ValidateBuild.cmake.in"
+  "${CMAKE_CURRENT_BINARY_DIR}/ValidateBuild.cmake"
+  @ONLY)
+
 # Source dir for this project exists outside the CMake build tree because it
 # is absolutely huge. Source dir is therefore cached under a '.cmake/Contracts'
 # dir in your HOME directory. Downloads are cached under '.cmake/Downloads'
@@ -82,6 +87,7 @@ else()
     URL "${url}"
     URL_MD5 "${md5}"
     SOURCE_DIR "${source_dir}"
+    PATCH_COMMAND ${CMAKE_COMMAND} -Dsource_dir=${source_dir} -P "${CMAKE_CURRENT_SOURCE_DIR}/Patch.cmake"
     CONFIGURE_COMMAND ""
     BUILD_COMMAND ""
     INSTALL_COMMAND ""
diff --git a/Tests/Contracts/Trilinos-10-6/Dashboard.cmake.in b/Tests/Contracts/Trilinos-10-6/Dashboard.cmake.in
index 1209dc8..cc29502 100644
--- a/Tests/Contracts/Trilinos-10-6/Dashboard.cmake.in
+++ b/Tests/Contracts/Trilinos-10-6/Dashboard.cmake.in
@@ -56,7 +56,8 @@ execute_process(COMMAND
   )
 
 if(NOT "${rv}" STREQUAL "0")
-  message(FATAL_ERROR "error(s) running Trilinos dashboard script experimental_build_test.cmake
+  message("error(s) (or warnings or test failures) running Trilinos dashboard
+script experimental_build_test.cmake...
 ctest returned rv='${rv}'
 ")
 endif()
diff --git a/Tests/Contracts/Trilinos-10-6/Patch.cmake b/Tests/Contracts/Trilinos-10-6/Patch.cmake
new file mode 100644
index 0000000..a7aae27
--- /dev/null
+++ b/Tests/Contracts/Trilinos-10-6/Patch.cmake
@@ -0,0 +1,20 @@
+if(NOT DEFINED source_dir)
+  message(FATAL_ERROR "variable 'source_dir' not defined")
+endif()
+
+if(NOT EXISTS "${source_dir}/CMakeLists.txt")
+  message(FATAL_ERROR "error: No CMakeLists.txt file to patch!")
+endif()
+
+set(text "
+
+#
+# Reference variables typically given as experimental_build_test configure
+# options to avoid CMake warnings about unused variables
+#
+
+MESSAGE(\"Trilinos_ALLOW_NO_PACKAGES='\${Trilinos_ALLOW_NO_PACKAGES}'\")
+MESSAGE(\"Trilinos_WARNINGS_AS_ERRORS_FLAGS='\${Trilinos_WARNINGS_AS_ERRORS_FLAGS}'\")
+")
+
+file(APPEND "${source_dir}/CMakeLists.txt" "${text}")
diff --git a/Tests/Contracts/Trilinos-10-6/RunTest.cmake b/Tests/Contracts/Trilinos-10-6/RunTest.cmake
index 93c1505..30124d8 100644
--- a/Tests/Contracts/Trilinos-10-6/RunTest.cmake
+++ b/Tests/Contracts/Trilinos-10-6/RunTest.cmake
@@ -1,4 +1,7 @@
-get_filename_component(dir "${CMAKE_CURRENT_LIST_FILE}" PATH)
+# ValidateBuild.cmake is configured into this location when the test is built:
+set(dir "${CMAKE_CURRENT_BINARY_DIR}/Contracts/${project}")
+
 set(exe "${CMAKE_COMMAND}")
 set(args -P "${dir}/ValidateBuild.cmake")
+
 set(Trilinos-10-6_RUN_TEST ${exe} ${args})
diff --git a/Tests/Contracts/Trilinos-10-6/ValidateBuild.cmake b/Tests/Contracts/Trilinos-10-6/ValidateBuild.cmake
deleted file mode 100644
index 6942b09..0000000
--- a/Tests/Contracts/Trilinos-10-6/ValidateBuild.cmake
+++ /dev/null
@@ -1,4 +0,0 @@
-# TODO: put some actual code here to validate that the Trilinos build was
-# "successful enough"
-#
-message(STATUS "Trilinos-10-6 build validated")
diff --git a/Tests/Contracts/Trilinos-10-6/ValidateBuild.cmake.in b/Tests/Contracts/Trilinos-10-6/ValidateBuild.cmake.in
new file mode 100644
index 0000000..04bbf21
--- /dev/null
+++ b/Tests/Contracts/Trilinos-10-6/ValidateBuild.cmake.in
@@ -0,0 +1,39 @@
+#
+# This code validates that the Trilinos build was "successful enough" (since it
+# is difficult to detect this from the caller of the experimental_build_test
+# dashboard script...)
+#
+set(binary_dir "@binary_dir@")
+message("binary_dir='${binary_dir}'")
+
+
+# Count *.exe files:
+#
+file(GLOB_RECURSE exes "${binary_dir}/*.exe")
+message(STATUS "exes='${exes}'")
+list(LENGTH exes len)
+if(len LESS 47)
+  message(FATAL_ERROR "len='${len}' is less than minimum expected='47' (count of executables)")
+endif()
+message(STATUS "Found len='${len}' *.exe files")
+
+
+# Try to find the Teuchos unit tests executable:
+#
+file(GLOB_RECURSE exe "${binary_dir}/Teuchos_UnitTest_UnitTests.exe")
+list(LENGTH exe len)
+if(NOT len EQUAL 1)
+  message(FATAL_ERROR "len='${len}' is not the expected='1' (count of Teuchos_UnitTest_UnitTests.exe)")
+endif()
+message(STATUS "Found exe='${exe}'")
+
+
+# Try to run it:
+execute_process(COMMAND ${exe} RESULT_VARIABLE rv)
+if(NOT "${rv}" STREQUAL "0")
+  message(FATAL_ERROR "rv='${rv}' is not the expected='0' (result of running Teuchos_UnitTest_UnitTests.exe)")
+endif()
+message(STATUS "Ran exe='${exe}' rv='${rv}'")
+
+
+message(STATUS "All Trilinos build validation tests pass.")

http://cmake.org/gitweb?p=cmake.git;a=commitdiff;h=73485615b2d66123b4952118440612d4f7bc9d0a
commit 73485615b2d66123b4952118440612d4f7bc9d0a
Author:     David Cole <david.cole at kitware.com>
AuthorDate: Tue Dec 28 08:53:04 2010 -0500
Commit:     David Cole <david.cole at kitware.com>
CommitDate: Tue Dec 28 08:53:04 2010 -0500

    Use m prefix in shorttag value to indicate "md5 of tarball"

diff --git a/Tests/Contracts/Trilinos-10-6/CMakeLists.txt b/Tests/Contracts/Trilinos-10-6/CMakeLists.txt
index 48a467a..3e06d4f 100644
--- a/Tests/Contracts/Trilinos-10-6/CMakeLists.txt
+++ b/Tests/Contracts/Trilinos-10-6/CMakeLists.txt
@@ -37,6 +37,7 @@ endif()
 message(STATUS "md5='${md5}'")
 
 string(SUBSTRING "${md5}" 0 8 shorttag)
+set(shorttag "m${shorttag}")
 
 set(download_dir "${HOME}/.cmake/Downloads")
 

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

Summary of changes:
 Tests/Contracts/Trilinos-10-6/CMakeLists.txt       |    7 ++++
 Tests/Contracts/Trilinos-10-6/Dashboard.cmake.in   |    3 +-
 Tests/Contracts/Trilinos-10-6/Patch.cmake          |   20 ++++++++++
 Tests/Contracts/Trilinos-10-6/RunTest.cmake        |    5 ++-
 Tests/Contracts/Trilinos-10-6/ValidateBuild.cmake  |    4 --
 .../Contracts/Trilinos-10-6/ValidateBuild.cmake.in |   39 ++++++++++++++++++++
 6 files changed, 72 insertions(+), 6 deletions(-)
 create mode 100644 Tests/Contracts/Trilinos-10-6/Patch.cmake
 delete mode 100644 Tests/Contracts/Trilinos-10-6/ValidateBuild.cmake
 create mode 100644 Tests/Contracts/Trilinos-10-6/ValidateBuild.cmake.in


hooks/post-receive
-- 
CMake


More information about the Cmake-commits mailing list