CMake: Use CMAKE_CL_64.
authorGerald Combs <gerald@wireshark.org>
Wed, 28 Oct 2015 23:52:41 +0000 (16:52 -0700)
committerGerald Combs <gerald@wireshark.org>
Thu, 29 Oct 2015 00:52:07 +0000 (00:52 +0000)
CMake sets CMAKE_CL_64 if we're using a 64-bit version of Visual Studio.
Use it.

Change-Id: I04595a0e703e39e428d853a506472f3881672a35
Reviewed-on: https://code.wireshark.org/review/11376
Petri-Dish: Gerald Combs <gerald@wireshark.org>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Gerald Combs <gerald@wireshark.org>
CMakeLists.txt

index bb149ca0ec6ce3174399cd934a5dbbe20a5f5dad..f0d0cd2fd1e8e270b9b72bc177f27db2c3b5630d 100644 (file)
@@ -65,7 +65,7 @@ endif()
 if(WIN32)
        find_package(PowerShell REQUIRED)
 
-       if("${CMAKE_GENERATOR}" MATCHES "Win64")
+       if(${CMAKE_CL_64} OR "${CMAKE_GENERATOR}" MATCHES "Win64")
                set(WIRESHARK_TARGET_PLATFORM win64)
        elseif("${CMAKE_GENERATOR}" MATCHES "Visual Studio")
                set(WIRESHARK_TARGET_PLATFORM win32)