[cmake-commits] hoffman committed CMakeLists.txt 1.59.2.6 1.59.2.9
cmTestConfigure.h.in 1.22 1.22.2.3
cmake-commits at cmake.org
cmake-commits at cmake.org
Fri Oct 13 10:52:12 EDT 2006
Update of /cvsroot/CMake/CMake/Tests/ComplexRelativePaths
In directory public:/mounts/ram/cvs-serv31017/Tests/ComplexRelativePaths
Modified Files:
Tag: CMake-2-4
CMakeLists.txt cmTestConfigure.h.in
Log Message:
ENH: merge changes from the main tree to the 2.4 branch
Index: CMakeLists.txt
===================================================================
RCS file: /cvsroot/CMake/CMake/Tests/ComplexRelativePaths/CMakeLists.txt,v
retrieving revision 1.59.2.6
retrieving revision 1.59.2.9
diff -u -d -r1.59.2.6 -r1.59.2.9
--- CMakeLists.txt 14 May 2006 19:22:47 -0000 1.59.2.6
+++ CMakeLists.txt 13 Oct 2006 14:52:08 -0000 1.59.2.9
@@ -100,8 +100,9 @@
INCLUDE_DIRECTORIES(BEFORE
${Complex_BINARY_DIR}
)
+INCLUDE_DIRECTORIES(SYSTEM Library/SystemDir)
-INCLUDE_REGULAR_EXPRESSION("^(cmTest|file|sharedFile).*$" "^cmMissing")
+INCLUDE_REGULAR_EXPRESSION("^(cmTest|file|sharedFile|test).*$" "^cmMissing")
LINK_DIRECTORIES(
${Complex_BINARY_DIR}/Library
@@ -271,6 +272,44 @@
SET(SHOULD_BE_ZERO )
SET(SHOULD_BE_ONE 1)
+
+# test elseif functionality, the mess below tries to catch problem
+# of clauses being executed early or late etc
+set (RESULT 3)
+if (RESULT EQUAL 1)
+ if (RESULT EQUAL 2)
+ set (ELSEIF_RESULT 1)
+ elseif (RESULT EQUAL 3)
+ set (ELSEIF_RESULT 1)
+ endif (RESULT EQUAL 2)
+elseif (RESULT EQUAL 2)
+ set (ELSEIF_RESULT 1)
+elseif (RESULT EQUAL 3)
+ if (RESULT EQUAL 2)
+ set (ELSEIF_RESULT 1)
+ elseif (RESULT EQUAL 3)
+ if (NOT ELSEIF_RESULT EQUAL 1)
+ set (ELSEIF_RESULT 2)
+ endif (NOT ELSEIF_RESULT EQUAL 1)
+ endif (RESULT EQUAL 2)
+elseif (RESULT EQUAL 4)
+ if (RESULT EQUAL 2)
+ set (ELSEIF_RESULT 1)
+ elseif (RESULT EQUAL 3)
+ set (ELSEIF_RESULT 1)
+ endif (RESULT EQUAL 2)
+else (RESULT EQUAL 1)
+ if (RESULT EQUAL 2)
+ set (ELSEIF_RESULT 1)
+ elseif (RESULT EQUAL 3)
+ set (ELSEIF_RESULT 1)
+ endif (RESULT EQUAL 2)
+endif (RESULT EQUAL 1)
+
+if (NOT ELSEIF_RESULT EQUAL 2)
+ set (ELSEIF_RESULT 0)
+endif (NOT ELSEIF_RESULT EQUAL 2)
+
#
# Configure file
# (plug vars to #define so that they can be tested)
@@ -303,6 +342,7 @@
"STRING(REGEX REPLACE ... ) test failed (\"${RESULT}\" v. \"a[b]c[d]e\")")
ENDIF(NOT STRING_REGEX_PASSED)
+
#
# Create the libs and the main exe
#
Index: cmTestConfigure.h.in
===================================================================
RCS file: /cvsroot/CMake/CMake/Tests/ComplexRelativePaths/cmTestConfigure.h.in,v
retrieving revision 1.22
retrieving revision 1.22.2.3
diff -u -d -r1.22 -r1.22.2.3
--- cmTestConfigure.h.in 16 Mar 2006 22:20:09 -0000 1.22
+++ cmTestConfigure.h.in 13 Oct 2006 14:52:08 -0000 1.22.2.3
@@ -77,3 +77,6 @@
#define CMAKE_SHARED_MODULE_PREFIX "${CMAKE_SHARED_MODULE_PREFIX}"
#define CMAKE_SHARED_MODULE_SUFFIX "${CMAKE_SHARED_MODULE_SUFFIX}"
+
+// test elseif
+#cmakedefine ELSEIF_RESULT
More information about the Cmake-commits
mailing list