diff options
author | Bill Hoffman <bill.hoffman@kitware.com> | 2009-01-27 15:34:14 (GMT) |
---|---|---|
committer | Bill Hoffman <bill.hoffman@kitware.com> | 2009-01-27 15:34:14 (GMT) |
commit | ef5b9d00a29bc55788c76dedfaa00571522f4ce2 (patch) | |
tree | d36abc14fc848b34d7c43cb6ebe8c9ee09e28e84 /Utilities | |
parent | 1dee719cdc0fe007235f3105df880cc51b597828 (diff) | |
download | CMake-ef5b9d00a29bc55788c76dedfaa00571522f4ce2.zip CMake-ef5b9d00a29bc55788c76dedfaa00571522f4ce2.tar.gz CMake-ef5b9d00a29bc55788c76dedfaa00571522f4ce2.tar.bz2 |
ENH: change to use CMAKE_CREATE_VERSION from CMAKE_VERSION as CMAKE_VERSION is auto-defined now
Diffstat (limited to 'Utilities')
-rw-r--r-- | Utilities/Release/README | 4 | ||||
-rw-r--r-- | Utilities/Release/create-cmake-release.cmake | 18 | ||||
-rw-r--r-- | Utilities/Release/release_cmake.cmake | 20 | ||||
-rwxr-xr-x | Utilities/Release/release_cmake.sh.in | 22 |
4 files changed, 32 insertions, 32 deletions
diff --git a/Utilities/Release/README b/Utilities/Release/README index 532f68a..75cdf48 100644 --- a/Utilities/Release/README +++ b/Utilities/Release/README @@ -2,7 +2,7 @@ To create a cmake release, first test the branch: mkdir 2-4 cd 2-4 -cmake -DCMAKE_VERSION=CMake-2-4 -P ../create-cmake-release.cmake +cmake -DCMAKE_CREATE_VERSION=CMake-2-4 -P ../create-cmake-release.cmake ./create-CMake-2-4.sh If that works: @@ -15,7 +15,7 @@ cvs tag 2-4-7 Then create a release from the tag: mkdir 2-4-7 cd 2-4-7 -cmake -DCMAKE_VERSION=CMake-2-4-7 -P ../create-cmake-release.cmake +cmake -DCMAKE_CREATE_VERSION=CMake-2-4-7 -P ../create-cmake-release.cmake ./create-CMake-2-4.sh diff --git a/Utilities/Release/create-cmake-release.cmake b/Utilities/Release/create-cmake-release.cmake index 37b93fb..93c7e44 100644 --- a/Utilities/Release/create-cmake-release.cmake +++ b/Utilities/Release/create-cmake-release.cmake @@ -1,6 +1,6 @@ -if(NOT DEFINED CMAKE_VERSION) - message(FATAL_ERROR "CMAKE_VERSION not defined") -endif(NOT DEFINED CMAKE_VERSION) +if(NOT DEFINED CMAKE_CREATE_VERSION) + message(FATAL_ERROR "CMAKE_CREATE_VERSION not defined") +endif(NOT DEFINED CMAKE_CREATE_VERSION) set(RELEASE_SCRIPTS dashmacmini2_release.cmake # Mac Darwin universal @@ -18,16 +18,16 @@ set(RELEASE_SCRIPTS # r15n65_aix_release.cmake # AIX 5.2 ) -file(WRITE create-${CMAKE_VERSION}.sh "#!/bin/sh") +file(WRITE create-${CMAKE_CREATE_VERSION}.sh "#!/bin/sh") make_directory(${CMAKE_CURRENT_SOURCE_DIR}/logs) foreach(f ${RELEASE_SCRIPTS}) - file(APPEND create-${CMAKE_VERSION}.sh + file(APPEND create-${CMAKE_CREATE_VERSION}.sh " -${CMAKE_COMMAND} -DCMAKE_VERSION=${CMAKE_VERSION} -P ${CMAKE_ROOT}/Utilities/Release/${f} < /dev/null >& ${CMAKE_CURRENT_SOURCE_DIR}/logs/${f}-${CMAKE_VERSION}.log & - xterm -geometry 80x10 -sb -sl 2000 -T ${f}-${CMAKE_VERSION}.log -e tail -f ${CMAKE_CURRENT_SOURCE_DIR}/logs/${f}-${CMAKE_VERSION}.log&") +${CMAKE_COMMAND} -DCMAKE_CREATE_VERSION=${CMAKE_CREATE_VERSION} -P ${CMAKE_ROOT}/Utilities/Release/${f} < /dev/null >& ${CMAKE_CURRENT_SOURCE_DIR}/logs/${f}-${CMAKE_CREATE_VERSION}.log & + xterm -geometry 80x10 -sb -sl 2000 -T ${f}-${CMAKE_CREATE_VERSION}.log -e tail -f ${CMAKE_CURRENT_SOURCE_DIR}/logs/${f}-${CMAKE_CREATE_VERSION}.log&") endforeach(f) -execute_process(COMMAND chmod a+x create-${CMAKE_VERSION}.sh) -message("Run ./create-${CMAKE_VERSION}.sh") +execute_process(COMMAND chmod a+x create-${CMAKE_CREATE_VERSION}.sh) +message("Run ./create-${CMAKE_CREATE_VERSION}.sh") diff --git a/Utilities/Release/release_cmake.cmake b/Utilities/Release/release_cmake.cmake index a977d1f..79c5457 100644 --- a/Utilities/Release/release_cmake.cmake +++ b/Utilities/Release/release_cmake.cmake @@ -26,22 +26,22 @@ endif(NOT DEFINED RUN_SHELL) if(NOT DEFINED PROCESSORS) set(PROCESSORS 1) endif(NOT DEFINED PROCESSORS) -if(NOT DEFINED CMAKE_VERSION) - message(FATAL_ERROR "CMAKE_VERSION not defined") -endif(NOT DEFINED CMAKE_VERSION) +if(NOT DEFINED CMAKE_CREATE_VERSION) + message(FATAL_ERROR "CMAKE_CREATE_VERSION not defined") +endif(NOT DEFINED CMAKE_CREATE_VERSION) if(NOT DEFINED CVS_COMMAND) set(CVS_COMMAND cvs) endif(NOT DEFINED CVS_COMMAND) -if("${CMAKE_VERSION}" STREQUAL "CVS") +if("${CMAKE_CREATE_VERSION}" STREQUAL "CVS") set( CMAKE_CHECKOUT "${CVS_COMMAND} -q -z3 -d ${CVSROOT} export -D now ") - set( CMAKE_VERSION "CurrentCVS") -else("${CMAKE_VERSION}" STREQUAL "CVS") - set( CMAKE_CHECKOUT "${CVS_COMMAND} -q -z3 -d ${CVSROOT} export -r ${CMAKE_VERSION} ") -endif("${CMAKE_VERSION}" STREQUAL "CVS") + set( CMAKE_CREATE_VERSION "CurrentCVS") +else("${CMAKE_CREATE_VERSION}" STREQUAL "CVS") + set( CMAKE_CHECKOUT "${CVS_COMMAND} -q -z3 -d ${CVSROOT} export -r ${CMAKE_CREATE_VERSION} ") +endif("${CMAKE_CREATE_VERSION}" STREQUAL "CVS") if(NOT DEFINED FINAL_PATH ) - set(FINAL_PATH ${CMAKE_RELEASE_DIRECTORY}/${CMAKE_VERSION}-build) + set(FINAL_PATH ${CMAKE_RELEASE_DIRECTORY}/${CMAKE_CREATE_VERSION}-build) endif(NOT DEFINED FINAL_PATH ) if(NOT HOST) @@ -51,7 +51,7 @@ if(NOT DEFINED MAKE) message(FATAL_ERROR "MAKE must be specified with -DMAKE=\"make -j2\"") endif(NOT DEFINED MAKE) -message("Creating CMake release ${CMAKE_VERSION} on ${HOST} with parallel = ${PROCESSORS}") +message("Creating CMake release ${CMAKE_CREATE_VERSION} on ${HOST} with parallel = ${PROCESSORS}") # define a macro to run a remote command macro(remote_command comment command) diff --git a/Utilities/Release/release_cmake.sh.in b/Utilities/Release/release_cmake.sh.in index 1487213..809e204 100755 --- a/Utilities/Release/release_cmake.sh.in +++ b/Utilities/Release/release_cmake.sh.in @@ -50,42 +50,42 @@ if [ ! -z "@USER_MAKE_RULE_FILE_CONTENTS@" ]; then check_exit_value $? "Create User Rule file" || exit 1 fi echo "Create a directory to build in" -rm -rf @CMAKE_RELEASE_DIRECTORY@/@CMAKE_VERSION@-build +rm -rf @CMAKE_RELEASE_DIRECTORY@/@CMAKE_CREATE_VERSION@-build check_exit_value $? "Remove build tree" || exit 1 -mkdir @CMAKE_RELEASE_DIRECTORY@/@CMAKE_VERSION@-build +mkdir @CMAKE_RELEASE_DIRECTORY@/@CMAKE_CREATE_VERSION@-build check_exit_value $? "Create build directory" || exit 1 # make sure directory was created -if [ ! -d @CMAKE_RELEASE_DIRECTORY@/@CMAKE_VERSION@-build ]; then - echo "Could not create @CMAKE_RELEASE_DIRECTORY@/@CMAKE_VERSION@-build" +if [ ! -d @CMAKE_RELEASE_DIRECTORY@/@CMAKE_CREATE_VERSION@-build ]; then + echo "Could not create @CMAKE_RELEASE_DIRECTORY@/@CMAKE_CREATE_VERSION@-build" exit -1 fi echo "Create initial cache" -echo "@INITIAL_CACHE@" > @CMAKE_RELEASE_DIRECTORY@/@CMAKE_VERSION@-build/CMakeCache.txt +echo "@INITIAL_CACHE@" > @CMAKE_RELEASE_DIRECTORY@/@CMAKE_CREATE_VERSION@-build/CMakeCache.txt check_exit_value $? "Create initial cache" || exit 1 #echo "Login into cvs." #echo "cmake" | @CVS_COMMAND@ -d @CVSROOT@ login -echo "Checkout the source for @CMAKE_VERSION@" +echo "Checkout the source for @CMAKE_CREATE_VERSION@" cd @CMAKE_RELEASE_DIRECTORY@ -@CMAKE_CHECKOUT@ -d @CMAKE_VERSION@ CMake +@CMAKE_CHECKOUT@ -d @CMAKE_CREATE_VERSION@ CMake check_exit_value $? "Checkout cmake source" || exit 1 -cd @CMAKE_RELEASE_DIRECTORY@/@CMAKE_VERSION@-build +cd @CMAKE_RELEASE_DIRECTORY@/@CMAKE_CREATE_VERSION@-build if [ ! -z "@CONFIGURE_WITH_CMAKE@" ]; then echo "Run cmake to configure cmake" - @CMAKE_CONFIGURE_PATH@ ../@CMAKE_VERSION@ + @CMAKE_CONFIGURE_PATH@ ../@CMAKE_CREATE_VERSION@ check_exit_value $? "Configure cmake" || exit 1 else if [ -z "@INSTALL_PREFIX@" ]; then echo "Run cmake bootstrap --parallel=@PROCESSORS@" - ../@CMAKE_VERSION@/bootstrap --parallel=@PROCESSORS@ + ../@CMAKE_CREATE_VERSION@/bootstrap --parallel=@PROCESSORS@ check_exit_value $? "Bootstrap cmake" || exit 1 else echo "Run cmake bootstrap --prefix=@INSTALL_PREFIX@ --parallel=@PROCESSORS@" - ../@CMAKE_VERSION@/bootstrap --prefix=@INSTALL_PREFIX@ --parallel=@PROCESSORS@ + ../@CMAKE_CREATE_VERSION@/bootstrap --prefix=@INSTALL_PREFIX@ --parallel=@PROCESSORS@ check_exit_value $? "Bootstrap cmake" || exit 1 fi fi |