diff options
Diffstat (limited to 'src/cmake/FindLIBUSB.cmake')
-rw-r--r-- | src/cmake/FindLIBUSB.cmake | 6 |
1 files 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) |