summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--CMakeLists.txt4
-rw-r--r--data/ShibokenConfigVersion.cmake.in17
2 files changed, 11 insertions, 10 deletions
diff --git a/CMakeLists.txt b/CMakeLists.txt
index f7087c18..429b38b2 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -7,8 +7,8 @@ set(CMAKE_MODULE_PATH ${CMAKE_SOURCE_DIR}/cmake/Modules/
${CMAKE_MODULE_PATH})
find_package(Qt4 4.5.0)
-find_package(ApiExtractor 0.9.4)
-find_package(GeneratorRunner 0.6.5)
+find_package(ApiExtractor 0.9.4 REQUIRED)
+find_package(GeneratorRunner 0.6.5 REQUIRED)
find_package(PythonLibs)
find_package(PythonInterpWithDebug)
diff --git a/data/ShibokenConfigVersion.cmake.in b/data/ShibokenConfigVersion.cmake.in
index 89d84fc1..b2658a96 100644
--- a/data/ShibokenConfigVersion.cmake.in
+++ b/data/ShibokenConfigVersion.cmake.in
@@ -1,9 +1,10 @@
set(PACKAGE_VERSION @shiboken_VERSION@)
-if("${PACKAGE_FIND_VERSION_MAJOR}" EQUAL @shiboken_MAJOR_VERSION@)
- if("${PACKAGE_FIND_VERSION_MINOR}" EQUAL @shiboken_MINOR_VERSION@)
- set(PACKAGE_VERSION_COMPATIBLE 1)
- if("${PACKAGE_FIND_VERSION_PATCH}" EQUAL @shiboken_MICRO_VERSION@)
- set(PACKAGE_VERSION_EXACT 1)
- endif()
- endif()
-endif()
+
+if("${PACKAGE_VERSION}" VERSION_LESS "${PACKAGE_FIND_VERSION}" )
+ set(PACKAGE_VERSION_COMPATIBLE FALSE)
+else("${PACKAGE_VERSION}" VERSION_LESS "${PACKAGE_FIND_VERSION}" )
+ set(PACKAGE_VERSION_COMPATIBLE TRUE)
+ if( "${PACKAGE_FIND_VERSION}" STREQUAL "${PACKAGE_VERSION}")
+ set(PACKAGE_VERSION_EXACT TRUE)
+ endif( "${PACKAGE_FIND_VERSION}" STREQUAL "${PACKAGE_VERSION}")
+endif("${PACKAGE_VERSION}" VERSION_LESS "${PACKAGE_FIND_VERSION}" )