blob: 391f2e3e29125c3b0469592f1af61a7d3a011ddd [file] [log] [blame]
Ewout van Bekkumc2f40802022-01-19 17:21:07 -08001# Copyright 2022 The Pigweed Authors
2#
3# Licensed under the Apache License, Version 2.0 (the "License"); you may not
4# use this file except in compliance with the License. You may obtain a copy of
5# the License at
6#
7# https://www.apache.org/licenses/LICENSE-2.0
8#
9# Unless required by applicable law or agreed to in writing, software
10# distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
11# WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
12# License for the specific language governing permissions and limitations under
13# the License.
14
15include($ENV{PW_ROOT}/pw_build/pigweed.cmake)
16
17pw_add_module_config(pw_chrono_freertos_CONFIG)
18
19pw_add_module_library(pw_chrono_freertos.config
20 HEADERS
21 public/pw_chrono_freertos/config.h
22 PUBLIC_INCLUDES
23 public
24 PUBLIC_DEPS
25 pw_third_party.freertos
26 ${pw_chrono_freertos_CONFIG}
27)
28
29# This target provides the backend for pw::chrono::SystemClock.
30pw_add_module_library(pw_chrono_freertos.system_clock
31 IMPLEMENTS_FACADES
32 pw_chrono.system_clock
33 HEADERS
34 public/pw_chrono_freertos/system_clock_config.h
35 public/pw_chrono_freertos/system_clock_constants.h
36 public_overrides/pw_chrono_backend/system_clock_config.h
37 PUBLIC_INCLUDES
38 public
39 public_overrides
40 PUBLIC_DEPS
41 pw_chrono_freertos.config
42 pw_chrono.epoch
43 pw_third_party.freertos
44 SOURCES
45 system_clock.cc
46 PRIVATE_DEPS
47 pw_interrupt.context
48 pw_sync.interrupt_spin_lock
49)
50
51# This target provides the backend for pw::chrono::SystemTimer.
52pw_add_module_library(pw_chrono_freertos.system_timer
53 IMPLEMENTS_FACADES
54 pw_chrono.system_timer
55 HEADERS
56 public/pw_chrono_freertos/system_timer_inline.h
57 public/pw_chrono_freertos/system_timer_native.h
58 public_overrides/pw_chrono_backend/system_timer_inline.h
59 public_overrides/pw_chrono_backend/system_timer_native.h
60 PUBLIC_INCLUDES
61 public
62 public_overrides
63 PUBLIC_DEPS
64 pw_chrono.system_clock
65 pw_third_party.freertos
66 SOURCES
67 system_timer.cc
68 PRIVATE_DEPS
69 pw_assert
70 pw_chrono_freertos.system_clock
71)