IF(LINUX) MESSAGE(STATUS 'sewpertest') FIND_PATH(BLUETOOTH_INCLUDE_DIR bluetooth.h /home/georgr/libbluetooth-dev/libbluetooth-dev/usr/include/bluetooth) FIND_LIBRARY(BLUETOOTH_LIBRARY NAMES bluetooth PATHS /usr/lib/x86_64-linux-gnu /home/georgr/libbluetooth-dev/libbluetooth-dev/usr/lib/x86_64-linux-gnu) MESSAGE(STATUS "sewpertest 2 ${BLUETOOTH_LIBRARY}") MESSAGE(STATUS "sewpertest 3 ${BLUETOOTH_INCLUDE_DIR}") IF(BLUETOOTH_INCLUDE_DIR AND BLUETOOTH_LIBRARY) SET(BLUETOOTH_FOUND TRUE) ENDIF(BLUETOOTH_INCLUDE_DIR AND BLUETOOTH_LIBRARY) ENDIF(LINUX) IF(APPLE) SET(BLUETOOTH_LIBRARY "-framework IOBluetooth") SET(BLUETOOTH_FOUND TRUE) ENDIF(APPLE) IF (BLUETOOTH_FOUND) IF (NOT Bluetooth_FIND_QUIETLY) MESSAGE(STATUS "Found Bluetooth: ${BLUETOOTH_LIBRARY}") ENDIF (NOT Bluetooth_FIND_QUIETLY) ELSE (BLUETOOTH_FOUND) IF (Bluetooth_FIND_REQUIRED) MESSAGE(FATAL_ERROR "Could not find Bluetooth. Please install Bluetooth package") ENDIF (Bluetooth_FIND_REQUIRED) ENDIF (BLUETOOTH_FOUND)