labapart / gattlib

Library to access GATT information from BLE (Bluetooth Low Energy) devices
http://labapart.com/
436 stars 157 forks source link

Allow gattlib to be added as a cmake subdirectory (add_subdirectory) #193

Closed ankurvdev closed 3 years ago

ankurvdev commented 3 years ago

Once added as a submodule the gattlib library can be linked as below

set(GATTLIB_BUILD_DOCS OFF CACHE BOOLEAN "")
set(GATTLIB_PYTHON_INTERFACE OFF CACHE BOOLEAN "")
add_subdirectory(${CMAKE_CURRENT_LIST_DIR}/gattlib gattlib)
target_link_libraries(bluetooth.linux.client PUBLIC gattlib Threads::Threads)
target_compile_options(gattlib PRIVATE
        -Wno-enum-conversion
        -Wno-sometimes-uninitialized
)
oliviermartin commented 3 years ago

Thanks @ankurverma85 for your contribution :-)