Fix regressiontests automated download
authorMark Abraham <mark.j.abraham@gmail.com>
Wed, 27 Feb 2013 15:29:42 +0000 (16:29 +0100)
committerGerrit Code Review <gerrit@gerrit.gromacs.org>
Tue, 5 Mar 2013 19:19:05 +0000 (20:19 +0100)
Refs #1150

Change-Id: I7ba82b22a75532516f481dcb5e4a870047c0bfe8

CMakeLists.txt
tests/CMakeLists.txt

index 03b524ece4a3acaf53c0b0b4b57cedc60fbe7ef5..a19ebf6be3507913f06b72ed950c05a1a9b4f07b 100644 (file)
@@ -57,6 +57,11 @@ mark_as_advanced(DART_ROOT)
 #
 # NOTE: when releasing the "-dev" suffix needs to be stripped off!
 set(PROJECT_VERSION "4.6.1-dev")
+# The version number of the regressiontest tarball against which this
+# git branch can be tested. Normally, this will be the version of the
+# last patch release. Comment the next line out for branches leading
+# to a major/minor release.
+set(REGRESSIONTEST_VERSION "4.6")
 set(CUSTOM_VERSION_STRING ""
     CACHE STRING "Custom version string (if empty, use hard-coded default)")
 mark_as_advanced(CUSTOM_VERSION_STRING)
index 6dfd7e639312b902740d532986f50caa6af9da02..ae47ede88d5f34fa5ba2a5c7a37d5ae50b52a1fe 100644 (file)
@@ -42,10 +42,8 @@ if(REGRESSIONTEST_DOWNLOAD AND CMAKE_VERSION VERSION_LESS "2.8.2")
         "REGRESSIONTEST_DOWNLOAD not supported with cmake ${CMAKE_VERSION}" FORCE)
 endif()
 if(REGRESSIONTEST_DOWNLOAD)
-    if("${PROJECT_VERSION}" MATCHES "-dev")
-        set(REGRESSIONTEST_VERSION master)
-    else()
-        set(REGRESSIONTEST_VERSION ${PROJECT_VERSION})
+    if(NOT REGRESSIONTEST_VERSION)
+        message(FATAL_ERROR "The configuration files do not specify what regressiontests tarball is suitable for automated download and testing. Please obtain and use a suitable set of tests yourself.")
     endif()
     set(REGRESSIONTEST_URL
         http://gerrit.gromacs.org/download/regressiontests-${REGRESSIONTEST_VERSION}.tar.gz)