From 56676deb38193054c79f7973d73dde01ed6f5451 Mon Sep 17 00:00:00 2001 From: "RALOVICH, Kristof" Date: Tue, 25 Jun 2013 13:47:38 +0200 Subject: cmake: fix determination of win64 --- src/cmake/FindLIBUSB.cmake | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/cmake/FindLIBUSB.cmake b/src/cmake/FindLIBUSB.cmake index a60f8c3..e68322e 100644 --- a/src/cmake/FindLIBUSB.cmake +++ b/src/cmake/FindLIBUSB.cmake @@ -28,13 +28,13 @@ IF(NOT LIBUSB_FOUND) IF(MSVC) # Windows with Microsoft Visual C++ FIND_PATH(LIBUSB_INCLUDE_DIRS NAMES usb.h lusb0_usb.h PATHS "$ENV{ProgramFiles}/LibUSB-Win32/include" "${LIBUSB_ROOT}/include") - IF(${CMAKE_SYSTEM_PROCESSOR} STREQUAL "x64") + IF(CMAKE_SIZEOF_VOID_P EQUAL 8) # on x64 (win64) FIND_LIBRARY(LIBUSB_LIBRARIES NAMES libusb PATHS "$ENV{ProgramFiles}/LibUSB-Win32/lib/msvc_x64" "${LIBUSB_ROOT}/lib/msvc_x64") - ELSE(${CMAKE_SYSTEM_PROCESSOR} STREQUAL "x64") + ELSE() # on x86 (win32) FIND_LIBRARY(LIBUSB_LIBRARIES NAMES libusb PATHS "$ENV{ProgramFiles}/LibUSB-Win32/lib/msvc" "${LIBUSB_ROOT}/lib/msvc") - ENDIF(${CMAKE_SYSTEM_PROCESSOR} STREQUAL "x64") + ENDIF() ELSE(MSVC) # If not MS Visual Studio we use PkgConfig FIND_PACKAGE (PkgConfig) -- cgit v1.2.3