-
Notifications
You must be signed in to change notification settings - Fork 0
/
CMakeLists.txt
64 lines (55 loc) · 1.54 KB
/
CMakeLists.txt
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
project(picoro CXX C ASM)
add_library(picoro_headers INTERFACE)
target_include_directories(picoro_headers INTERFACE include)
add_library(picoro_coroutine INTERFACE)
# Enable coroutines (GCC 10 requires a flag).
target_compile_options(picoro_coroutine INTERFACE $<$<COMPILE_LANGUAGE:CXX>:-fcoroutines>)
target_link_libraries(picoro_coroutine INTERFACE
picoro_headers
)
add_library(picoro_debug INTERFACE)
target_link_libraries(picoro_debug INTERFACE
picoro_headers
pico_stdio
)
add_library(picoro_event_loop INTERFACE)
target_link_libraries(picoro_event_loop INTERFACE
picoro_headers
picoro_debug
pico_async_context_poll
)
add_library(picoro_sleep INTERFACE)
target_link_libraries(picoro_sleep INTERFACE
picoro_headers
picoro_event_loop
pico_time
)
add_library(picoro_tcp INTERFACE)
target_link_libraries(picoro_tcp INTERFACE
picoro_headers
picoro_debug
pico_cyw43_arch_lwip_poll
)
add_library(picoro_drivers_sensirion_scd4x INTERFACE)
target_link_libraries(picoro_drivers_sensirion_scd4x INTERFACE
picoro_headers
picoro_coroutine
picoro_sleep
hardware_i2c
)
add_library(picoro_drivers_sensirion_sht3x INTERFACE)
target_link_libraries(picoro_drivers_sensirion_sht3x INTERFACE
picoro_headers
picoro_coroutine
picoro_sleep
hardware_i2c
)
add_library(picoro_drivers_dht22 INTERFACE)
pico_generate_pio_header(picoro_drivers_dht22 ${CMAKE_CURRENT_LIST_DIR}/include/picoro/drivers/dht22.pio)
target_link_libraries(picoro_drivers_dht22 INTERFACE
picoro_headers
picoro_coroutine
hardware_clocks
hardware_dma
hardware_pio
)