From 8fb30660b5a9bc2dab2e85ddd77b44981b209d06 Mon Sep 17 00:00:00 2001 From: Marian Buschsieweke Date: Tue, 9 Feb 2021 20:52:31 +0100 Subject: [PATCH] makefiles/features_check.inc.mk: fix declaration order FEATURES_CONFLICTING previously was declared prior to the function it is calling, resulting in empty output during the first dependency resolution iteration. This fixes the order so that the conflicting features are detected right from the first recursion. --- makefiles/features_check.inc.mk | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/makefiles/features_check.inc.mk b/makefiles/features_check.inc.mk index abca2fb644..8438ab5d45 100644 --- a/makefiles/features_check.inc.mk +++ b/makefiles/features_check.inc.mk @@ -47,11 +47,6 @@ FEATURES_USED := $(sort $(FEATURES_REQUIRED) \ $(FEATURES_REQUIRED_ONE_OUT_OF) \ $(FEATURES_OPTIONAL_USED)) -# Used features that conflict when used together -FEATURES_CONFLICTING := $(sort $(foreach conflict,\ - $(FEATURES_CONFLICT),\ - $(call _features_conflicting,$(conflict)))) - # Return conflicting features from the conflict string feature1:feature2 # $1: feature1:feature2 # Return the list of conflicting features @@ -61,6 +56,11 @@ _features_conflicting = $(if $(call _features_used_conflicting,$(subst :, ,$1)), # Return non empty on error _features_used_conflicting = $(filter $(words $1),$(words $(filter $(FEATURES_USED),$1))) +# Used features that conflict when used together +FEATURES_CONFLICTING := $(sort $(foreach conflict,\ + $(FEATURES_CONFLICT),\ + $(call _features_conflicting,$(conflict)))) + # Features that are used by the application but blacklisted by the BSP. # Having blacklisted features may cause the build to fail. FEATURES_USED_BLACKLISTED := $(sort $(filter $(FEATURES_USED), $(FEATURES_BLACKLIST)))