list(APPEND SOURCE_FILES Bluetooth.cpp) list(APPEND SOURCE_FILES BluetoothImpl.h) list(APPEND SOURCE_FILES ByteBuffer.cpp) list(APPEND SOURCE_FILES log.h) list(APPEND SOURCE_FILES "${PROJECT_SOURCE_DIR}/include/ble/Bluetooth.h") list(APPEND SOURCE_FILES "${PROJECT_SOURCE_DIR}/include/ble/ByteBuffer.h") if(IS_LINUX) list(APPEND SOURCE_FILES LinuxBluetooth.cpp LinuxBluetooth.h) list(APPEND COMPILE_OPTIONS -DIS_LINUX) elseif(IS_APPLE) list(APPEND SOURCE_FILES OsxBluetooth.mm OsxBluetooth.h) list(APPEND COMPILE_OPTIONS -DIS_APPLE) endif() find_package(Boost COMPONENTS regex system program_options REQUIRED) add_library(ble ${SOURCE_FILES}) target_include_directories(ble PUBLIC "${PROJECT_SOURCE_DIR}/include") target_include_directories(ble PUBLIC "${Boost_INCLUDE_DIRS}") target_compile_options(ble PRIVATE -Wno-deprecated-register ${COMPILE_OPTIONS})