summaryrefslogtreecommitdiff
path: root/Source/cmIfCommand.h
diff options
context:
space:
mode:
authorBrad King <brad.king@kitware.com>2008-09-10 11:58:40 -0400
committerBrad King <brad.king@kitware.com>2008-09-10 11:58:40 -0400
commit4fa96dbf95bb3689fb1c3283c38713ec5275f262 (patch)
treefdf7858be3ec641926a37794ed4e8d906f2e3b52 /Source/cmIfCommand.h
parent4ed4f5a7d4e399b9ac247aff7fec7cda61bfb5d1 (diff)
downloadcmake-4fa96dbf95bb3689fb1c3283c38713ec5275f262.tar.gz
ENH: Add version comparison to if() command
Provide VERSION_LESS, VERSION_EQUAL, and VERSION_GREATER operators in the if() command. This simplifies component-wise comparison of version numbers in the form "major[.minor[.patch[.tweak]]]".
Diffstat (limited to 'Source/cmIfCommand.h')
-rw-r--r--Source/cmIfCommand.h5
1 files changed, 5 insertions, 0 deletions
diff --git a/Source/cmIfCommand.h b/Source/cmIfCommand.h
index 6c23aa0f5a..bc84e569d5 100644
--- a/Source/cmIfCommand.h
+++ b/Source/cmIfCommand.h
@@ -177,6 +177,11 @@ public:
" if(string STREQUAL string)\n"
"True if the given string or variable's value is lexicographically "
"less (or greater, or equal) than the string on the right.\n"
+ " if(version1 VERSION_LESS version2)\n"
+ " if(version1 VERSION_EQUAL version2)\n"
+ " if(version1 VERSION_GREATER version2)\n"
+ "Component-wise integer version number comparison (version format is "
+ "major[.minor[.patch[.tweak]]]).\n"
" if(DEFINED variable)\n"
"True if the given variable is defined. It does not matter if the "
"variable is true or false just if it has been set.";