summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorBrad King <brad.king@kitware.com>2014-02-12 16:31:26 (GMT)
committerCMake Topic Stage <kwrobot@kitware.com>2014-02-12 16:31:26 (GMT)
commit0d177cf383fbca1d23fcd57672683d66c403d738 (patch)
tree63e3a38df46db68c5bbe539af07507f90da0681e
parente6f0b870fd69206d9e7848a07135dde809beddc2 (diff)
parent6ca6613ab8a30da726118b31e1c6fb11c54e6cdd (diff)
downloadCMake-0d177cf383fbca1d23fcd57672683d66c403d738.zip
CMake-0d177cf383fbca1d23fcd57672683d66c403d738.tar.gz
CMake-0d177cf383fbca1d23fcd57672683d66c403d738.tar.bz2
Merge topic 'cmake-devel-version-macro'
6ca6613a Export: Use the CMAKE_DEVEL_VERSION macro for build-export files.
-rw-r--r--Source/cmExportBuildFileGenerator.cxx2
-rw-r--r--Source/cmExportFileGenerator.h15
-rw-r--r--Source/cmExportInstallFileGenerator.cxx14
3 files changed, 16 insertions, 15 deletions
diff --git a/Source/cmExportBuildFileGenerator.cxx b/Source/cmExportBuildFileGenerator.cxx
index 858f76c..a77bc68 100644
--- a/Source/cmExportBuildFileGenerator.cxx
+++ b/Source/cmExportBuildFileGenerator.cxx
@@ -52,7 +52,7 @@ bool cmExportBuildFileGenerator::GenerateMainFile(std::ostream& os)
}
if (te->GetType() == cmTarget::INTERFACE_LIBRARY)
{
- this->GenerateRequiredCMakeVersion(os, "2.8.12.20131007"); // 2.8.13
+ this->GenerateRequiredCMakeVersion(os, DEVEL_CMAKE_VERSION(3, 0, 0));
}
}
diff --git a/Source/cmExportFileGenerator.h b/Source/cmExportFileGenerator.h
index 1438f4d..8be4bbf 100644
--- a/Source/cmExportFileGenerator.h
+++ b/Source/cmExportFileGenerator.h
@@ -15,6 +15,21 @@
#include "cmCommand.h"
#include "cmGeneratorExpression.h"
+#include "cmVersionMacros.h"
+#include "cmVersion.h"
+
+#define STRINGIFY_HELPER(X) #X
+#define STRINGIFY(X) STRINGIFY_HELPER(X)
+
+#define DEVEL_CMAKE_VERSION(maj, min, patch) \
+ (CMake_VERSION_ENCODE(maj, min, patch) > \
+ CMake_VERSION_ENCODE(CMake_VERSION_MAJOR, CMake_VERSION_MINOR, \
+ CMake_VERSION_PATCH) \
+ ) ? \
+ STRINGIFY(CMake_VERSION_MAJOR) "." STRINGIFY(CMake_VERSION_MINOR) "." \
+ STRINGIFY(CMake_VERSION_PATCH) "." STRINGIFY(CMake_VERSION_TWEAK) \
+ : #maj "." #min "." #patch
+
class cmTargetExport;
/** \class cmExportFileGenerator
diff --git a/Source/cmExportInstallFileGenerator.cxx b/Source/cmExportInstallFileGenerator.cxx
index 56c0ec1..8b59665 100644
--- a/Source/cmExportInstallFileGenerator.cxx
+++ b/Source/cmExportInstallFileGenerator.cxx
@@ -19,20 +19,6 @@
#include "cmInstallExportGenerator.h"
#include "cmInstallTargetGenerator.h"
#include "cmTargetExport.h"
-#include "cmVersionMacros.h"
-#include "cmVersion.h"
-
-#define STRINGIFY_HELPER(X) #X
-#define STRINGIFY(X) STRINGIFY_HELPER(X)
-
-#define DEVEL_CMAKE_VERSION(maj, min, patch) \
- (CMake_VERSION_ENCODE(maj, min, patch) > \
- CMake_VERSION_ENCODE(CMake_VERSION_MAJOR, CMake_VERSION_MINOR, \
- CMake_VERSION_PATCH) \
- ) ? \
- STRINGIFY(CMake_VERSION_MAJOR) "." STRINGIFY(CMake_VERSION_MINOR) "." \
- STRINGIFY(CMake_VERSION_PATCH) "." STRINGIFY(CMake_VERSION_TWEAK) \
- : #maj "." #min "." #patch
//----------------------------------------------------------------------------
cmExportInstallFileGenerator