[riot-notifications] [RIOT-OS/RIOT] ble/skald: switch from xtimer to ZTIMER_MSEC (#15805)

Francisco notifications at github.com
Mon Jan 25 14:26:04 CET 2021


> will look into the module deps soonish, but last time I tried to do it using `FEATURES_OPTIIONAL` it failed. But maybe it was just some mistake in my side...

This patch should work unless you want `periph_rtt` to be required, but this way the application would still build for boards that do not have an rtt.

```diff
diff --git a/sys/Makefile.dep b/sys/Makefile.dep
index 26cc3c9ded..64f4f3b50b 100644
--- a/sys/Makefile.dep
+++ b/sys/Makefile.dep
@@ -918,7 +918,10 @@ ifneq (,$(filter skald,$(USEMODULE)))
   USEMODULE += nrfble
   USEMODULE += random
   USEMODULE += ztimer_msec
-  USEMODULE += ztimer_periph_rtt
+  FEATURES_OPTIONAL += periph_rtt
+  ifneq (,$(filter periph_rtt,$(FEATURES_USED)))
+    USEMODULE += ztimer_periph_rtt
+  endif
 endif
 
 ifneq (,$(filter bluetil_addr,$(USEMODULE)))

```

```
make -C examples/skald_ibeacon/ info-modules | grep rtt
periph_init_rtt
periph_rtt
ztimer_periph_rtt
```

```
BOARD=nucleo-l152re make -C examples/skald_ibeacon/ info-modules | grep rtt
# empty
```

-- 
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/RIOT-OS/RIOT/pull/15805#issuecomment-766814220
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.riot-os.org/pipermail/notifications/attachments/20210125/d47d2f44/attachment.htm>


More information about the notifications mailing list