1# SPDX-License-Identifier: Apache-2.0
2
3if(CONFIG_BT_LL_SW_SPLIT)
4  zephyr_library_sources(
5    ll_sw/nordic/lll/lll.c
6    ll_sw/nordic/lll/lll_clock.c
7    )
8  if(CONFIG_BT_BROADCASTER)
9    zephyr_library_sources(
10      ll_sw/nordic/lll/lll_adv.c
11      )
12    zephyr_library_sources_ifdef(
13      CONFIG_BT_CTLR_ADV_EXT
14      ll_sw/nordic/lll/lll_adv_aux.c
15      )
16    zephyr_library_sources_ifdef(
17      CONFIG_BT_CTLR_ADV_PERIODIC
18      ll_sw/nordic/lll/lll_adv_sync.c
19      )
20    zephyr_library_sources_ifdef(
21      CONFIG_BT_CTLR_ADV_ISO
22      ll_sw/nordic/lll/lll_adv_iso.c
23      )
24  endif()
25  if(CONFIG_BT_OBSERVER)
26    zephyr_library_sources(
27      ll_sw/nordic/lll/lll_scan.c
28      )
29    zephyr_library_sources_ifdef(
30      CONFIG_BT_CTLR_ADV_EXT
31      ll_sw/nordic/lll/lll_scan_aux.c
32      )
33    zephyr_library_sources_ifdef(
34      CONFIG_BT_CTLR_SYNC_PERIODIC
35      ll_sw/nordic/lll/lll_sync.c
36      )
37    zephyr_library_sources_ifdef(
38      CONFIG_BT_CTLR_SYNC_ISO
39      ll_sw/nordic/lll/lll_sync_iso.c
40      )
41  endif()
42  if(CONFIG_BT_CONN)
43    zephyr_library_sources(
44      ll_sw/nordic/lll/lll_conn.c
45      )
46    zephyr_library_sources_ifdef(
47      CONFIG_BT_PERIPHERAL
48      ll_sw/nordic/lll/lll_peripheral.c
49      )
50    zephyr_library_sources_ifdef(
51      CONFIG_BT_CENTRAL
52      ll_sw/nordic/lll/lll_central.c
53      )
54  endif()
55  zephyr_library_sources_ifdef(
56    CONFIG_BT_CTLR_DTM
57    ll_sw/nordic/lll/lll_test.c
58    )
59  zephyr_library_sources_ifdef(
60    CONFIG_BT_CTLR_PROFILE_ISR
61    ll_sw/nordic/lll/lll_prof.c
62    )
63  zephyr_library_sources_ifdef(
64    CONFIG_BT_CTLR_DF
65    ll_sw/nordic/lll/lll_df.c
66    )
67  if(CONFIG_BT_CTLR_DF AND NOT CONFIG_SOC_SERIES_BSIM_NRFXX)
68    zephyr_library_sources(ll_sw/nordic/hal/nrf5/radio/radio_df.c)
69  endif()
70  if(CONFIG_BT_CTLR_CONN_ISO)
71    zephyr_library_sources(
72      ll_sw/nordic/lll/lll_conn_iso.c
73      )
74  endif()
75  zephyr_library_sources_ifdef(
76    CONFIG_BT_CTLR_CENTRAL_ISO
77    ll_sw/nordic/lll/lll_central_iso.c
78    )
79  zephyr_library_sources_ifdef(
80    CONFIG_BT_CTLR_PERIPHERAL_ISO
81    ll_sw/nordic/lll/lll_peripheral_iso.c
82    )
83  if(CONFIG_BT_CTLR_ISO_VENDOR_DATA_PATH)
84    zephyr_library_sources(
85      ll_sw/nordic/ull/ull_iso_vendor.c
86      )
87  endif()
88endif()
89
90zephyr_library_sources(
91  ll_sw/nordic/hal/nrf5/cntr.c
92  ll_sw/nordic/hal/nrf5/ecb.c
93  ll_sw/nordic/hal/nrf5/radio/radio.c
94  ll_sw/nordic/hal/nrf5/mayfly.c
95  ll_sw/nordic/hal/nrf5/ticker.c
96  )
97
98zephyr_library_sources_ifdef(
99  CONFIG_SOC_FAMILY_NRF
100  hci/nordic/hci_vendor.c
101  )
102
103zephyr_library_include_directories(
104  ll_sw
105  ll_sw/nordic
106  hci/nordic
107)
108
109# This path needs to be added globally as it is supposed to be used
110# in nrfx_glue.h when other libraries are built.
111zephyr_include_directories(
112  ll_sw/nordic/hal/nrf5/nrfx_glue
113)
114