summaryrefslogtreecommitdiffstats
path: root/Modules/BasicConfigVersion-SameMajorVersion.cmake.in
diff options
context:
space:
mode:
authorAlex Neundorf <neundorf@kde.org>2012-05-23 18:46:48 (GMT)
committerAlex Neundorf <neundorf@kde.org>2012-05-23 18:46:48 (GMT)
commit00ae36fdfffe39fb71cb54f81990b44be81d6833 (patch)
treeacbdcb77cdd3d72a01859e24e9685598b09c405b /Modules/BasicConfigVersion-SameMajorVersion.cmake.in
parentf2656e4ccb7b05cb1bef17ccf61dc9af7ed3f5fc (diff)
downloadCMake-00ae36fdfffe39fb71cb54f81990b44be81d6833.zip
CMake-00ae36fdfffe39fb71cb54f81990b44be81d6833.tar.gz
CMake-00ae36fdfffe39fb71cb54f81990b44be81d6833.tar.bz2
write_basic_package_version_file() now works with unset CMAKE_SIZEOF_VOID_P
This fixes #13241. If CMAKE_SIZEOF_VOID_P is not set, either in the installed or in the using project, don't check for it. Alex
Diffstat (limited to 'Modules/BasicConfigVersion-SameMajorVersion.cmake.in')
-rw-r--r--Modules/BasicConfigVersion-SameMajorVersion.cmake.in5
1 files changed, 5 insertions, 0 deletions
diff --git a/Modules/BasicConfigVersion-SameMajorVersion.cmake.in b/Modules/BasicConfigVersion-SameMajorVersion.cmake.in
index 2317fdb..7bcea88 100644
--- a/Modules/BasicConfigVersion-SameMajorVersion.cmake.in
+++ b/Modules/BasicConfigVersion-SameMajorVersion.cmake.in
@@ -33,6 +33,11 @@ else()
endif()
+# if the installed or the using project don't have CMAKE_SIZEOF_VOID_P set, ignore it:
+if("${CMAKE_SIZEOF_VOID_P}" STREQUAL "" OR "@CMAKE_SIZEOF_VOID_P@" STREQUAL "")
+ return()
+endif()
+
# check that the installed version has the same 32/64bit-ness as the one which is currently searching:
if(NOT "${CMAKE_SIZEOF_VOID_P}" STREQUAL "@CMAKE_SIZEOF_VOID_P@")
math(EXPR installedBits "@CMAKE_SIZEOF_VOID_P@ * 8")