Rex Dieter 29094f
From 4a16ae0eb9b5f542877100364f92b77fa30c987e Mon Sep 17 00:00:00 2001
Rex Dieter 29094f
From: Alexander Neundorf <neundorf@kde.org>
Rex Dieter 29094f
Date: Sat, 9 May 2009 11:31:03 +0000
Rex Dieter 29094f
Subject: [PATCH 13/33] -add documentation -adapt to changes in
Rex Dieter 29094f
 KDECTestNightly.cmake in kdesdk
Rex Dieter 29094f
Rex Dieter 29094f
Alex
Rex Dieter 29094f
Rex Dieter 29094f
Rex Dieter 29094f
Rex Dieter 29094f
svn path=/trunk/kdesupport/automoc/; revision=965571
Rex Dieter 29094f
---
Rex Dieter 29094f
 Automoc4Nightly.cmake | 26 +++++++++++++++++++++++++-
Rex Dieter 29094f
 1 file changed, 25 insertions(+), 1 deletion(-)
Rex Dieter 29094f
Rex Dieter 29094f
diff --git a/Automoc4Nightly.cmake b/Automoc4Nightly.cmake
Rex Dieter 29094f
index a4cd5a8..ad3aeb9 100644
Rex Dieter 29094f
--- a/Automoc4Nightly.cmake
Rex Dieter 29094f
+++ b/Automoc4Nightly.cmake
Rex Dieter 29094f
@@ -1,5 +1,21 @@
Rex Dieter 29094f
+# This is a script for running a Nightly build of automoc4.
Rex Dieter 29094f
+# It is ready for testing.
Rex Dieter 29094f
+# To adapt it for other projects, basically only the KDE_CTEST_VCS_REPOSITORY variable
Rex Dieter 29094f
+# has to be changed.
Rex Dieter 29094f
+#
Rex Dieter 29094f
+# It uses the file KDECTestNightly.cmake, which is in KDE svn in kdesdk/cmake/modules/. 
Rex Dieter 29094f
+# You need to have this file on some location on your system and then point the environment variable
Rex Dieter 29094f
+# KDECTESTNIGHTLY_DIR to the directory containing this file when running this script.
Rex Dieter 29094f
+#
Rex Dieter 29094f
+# For more details have a look at kdelibs/KDELibsNightly.cmake in KDE svn 
Rex Dieter 29094f
+#
Rex Dieter 29094f
+# Alex <neundorf AT kde.org>
Rex Dieter 29094f
+
Rex Dieter 29094f
+# The VCS of KDE is "svn", also specify the repository
Rex Dieter 29094f
 set(KDE_CTEST_VCS svn)
Rex Dieter 29094f
 set(KDE_CTEST_VCS_REPOSITORY https://svn.kde.org/home/kde/trunk/kdesupport/automoc)
Rex Dieter 29094f
+
Rex Dieter 29094f
+# for now hardcode the generator to "Unix Makefiles"
Rex Dieter 29094f
 set(CTEST_CMAKE_GENERATOR "Unix Makefiles" )
Rex Dieter 29094f
 
Rex Dieter 29094f
 # set(CTEST_AVOID_SPACES FALSE)
Rex Dieter 29094f
@@ -14,20 +30,28 @@ Set the environment variable KDECTESTNIGHTLY_DIR  to the directory where this fi
Rex Dieter 29094f
 In KDE svn it is in kdesdk/cmake/modules/ ")
Rex Dieter 29094f
 endif(NOT fileIncluded)
Rex Dieter 29094f
 
Rex Dieter 29094f
+# set up binary dir, source dir, etc.
Rex Dieter 29094f
 kde_ctest_setup("${CMAKE_CURRENT_LIST_FILE}")
Rex Dieter 29094f
 
Rex Dieter 29094f
 ctest_empty_binary_directory("${CTEST_BINARY_DIRECTORY}")
Rex Dieter 29094f
 ctest_start(Nightly)
Rex Dieter 29094f
 ctest_update(SOURCE "${CTEST_SOURCE_DIRECTORY}" )
Rex Dieter 29094f
 
Rex Dieter 29094f
+# read some settings
Rex Dieter 29094f
 include("${CTEST_SOURCE_DIRECTORY}/CTestConfig.cmake")
Rex Dieter 29094f
 include("${CTEST_SOURCE_DIRECTORY}/CTestCustom.cmake" OPTIONAL)
Rex Dieter 29094f
 
Rex Dieter 29094f
+# if CMAKE_INSTALL_PREFIX was defined on the command line, put it in the initial cache, so cmake gets it
Rex Dieter 29094f
 kde_ctest_write_initial_cache("${CTEST_BINARY_DIRECTORY}" CMAKE_INSTALL_PREFIX )
Rex Dieter 29094f
 
Rex Dieter 29094f
+# configure, build, test, submit
Rex Dieter 29094f
 ctest_configure(BUILD "${CTEST_BINARY_DIRECTORY}" )
Rex Dieter 29094f
 ctest_build(BUILD "${CTEST_BINARY_DIRECTORY}" )
Rex Dieter 29094f
 ctest_test(BUILD "${CTEST_BINARY_DIRECTORY}" )
Rex Dieter 29094f
 ctest_submit()
Rex Dieter 29094f
 
Rex Dieter 29094f
-kde_ctest_install( "${CTEST_BINARY_DIRECTORY}" )
Rex Dieter 29094f
+# optionally install afterwards, so additional nightly builds can use this current install 
Rex Dieter 29094f
+# (e.g. kdepimlibs could use this kdelibs install)
Rex Dieter 29094f
+if(DO_INSTALL)
Rex Dieter 29094f
+   kde_ctest_install( "${CTEST_BINARY_DIRECTORY}" )
Rex Dieter 29094f
+endif(DO_INSTALL)
Rex Dieter 29094f
-- 
Rex Dieter 29094f
2.4.3
Rex Dieter 29094f