vibe-check/CMakeLists.txt

40 lines
880 B
CMake
Raw Normal View History

2023-04-21 17:11:54 +01:00
cmake_minimum_required(VERSION 3.13)
2023-04-21 21:57:54 +01:00
set(PICO_SDK_PATH ${CMAKE_SOURCE_DIR}/lib/pico-sdk/)
include(${PICO_SDK_PATH}/external/pico_sdk_import.cmake)
2023-04-21 17:11:54 +01:00
project(vibe-check)
pico_sdk_init()
include_directories(
${CMAKE_SOURCE_DIR}/lib/rtt/RTT
2023-04-24 00:11:18 +01:00
${CMAKE_SOURCE_DIR}/src
)
2023-04-21 17:11:54 +01:00
add_executable(vibe-check
2023-04-24 00:11:18 +01:00
# BTStack seems to embed and link against RTT(!)
# lib/rtt/RTT/SEGGER_RTT.c
src/stdio_rtt.c
2023-04-21 17:11:54 +01:00
src/main.c
2023-04-24 20:59:20 +01:00
src/state.c
2023-04-24 00:11:18 +01:00
src/vibe_bt.c
2023-04-21 17:11:54 +01:00
)
2023-04-23 18:23:28 +01:00
target_link_libraries(vibe-check
pico_stdlib
pico_cyw43_arch_none
2023-04-24 00:11:18 +01:00
pico_btstack_ble
pico_btstack_cyw43
2023-04-25 13:47:56 +01:00
hardware_pwm
2023-04-23 18:23:28 +01:00
)
2023-04-21 17:11:54 +01:00
2023-04-24 00:11:18 +01:00
pico_btstack_make_gatt_header(vibe-check PRIVATE "${CMAKE_SOURCE_DIR}/src/vibe.gatt")
2023-04-23 20:01:15 +01:00
# enable debug logging to USB and UART
pico_enable_stdio_usb(vibe-check 1)
pico_enable_stdio_uart(vibe-check 1)
2023-04-21 17:11:54 +01:00
# create map/bin/hex/uf2 file in addition to ELF.
pico_add_extra_outputs(vibe-check)