Skip to content

Commit 8ea9a42

Browse files
committed
buildsystem: fix boards/Makefile.features inclusion
1 parent 3399b64 commit 8ea9a42

File tree

2 files changed

+7
-3
lines changed

2 files changed

+7
-3
lines changed

Makefile.features

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -4,16 +4,16 @@
44
# variables in their Makefile.features.
55
# This makes them available when setting features based on CPU_MODEL in the cpu
66
# Makefile.features and also during dependency resolution.
7+
#
8+
# Board features defined by common code in `boards/common` are processed
9+
# during the dependency resolution, since they depend on the USEMODULE.
710

811
# Transition:
912
# Moving 'CPU/CPU_MODEL' to Makefile.features is an ongoing work and may not
1013
# reflect the state of all boards for the moment.
1114

1215
include $(BOARDDIR)/Makefile.features
1316

14-
# include global Makefile.features for `boards` modules
15-
include $(RIOTBOARD)/Makefile.features
16-
1717
# Sanity check
1818
ifeq (,$(CPU))
1919
$(error $(BOARD): CPU must be defined by board / board_common Makefile.features)

makefiles/dependency_resolution.inc.mk

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -17,6 +17,10 @@ OLD_STATE := $(USEMODULE) $(USEPKG) $(FEATURES_USED)
1717
# pull in dependencies of the currently used modules and pkgs
1818
include $(RIOTBASE)/Makefile.dep
1919

20+
# include the global board features before the feature check as they depend
21+
# on the USEMODULE, which is present after the `Makefile.dep` resolution
22+
include $(RIOTBOARD)/Makefile.features
23+
2024
# check if required features are provided and update $(FEATURES_USED)
2125
include $(RIOTMAKE)/features_check.inc.mk
2226

0 commit comments

Comments
 (0)