BUILD: makefile: build the features list dynamically
The BUILD_FEATURES string was created too early to inherit implicit additions. This could make the features list report that some features were disabled while they had later been enabled. Better make it a macro that is interpreted where needed based on the current state of each option. (cherry picked from commit 39d6c348370a8d801b918263a551e300696dd64b) Signed-off-by: Willy Tarreau <w@1wt.eu> (cherry picked from commit 650959acbecc2a607629fd905a39e0689a02ec92) Signed-off-by: Christopher Faulet <cfaulet@haproxy.com>
This commit is contained in:
parent
ba2817bba8
commit
161ba95c0f
6
Makefile
6
Makefile
@ -553,7 +553,11 @@ ignore_implicit = $(if $(subst environment,,$(origin $(1))), \
|
||||
# is used to report a list of all flags which were used to build this version.
|
||||
# Do not assign anything to it.
|
||||
BUILD_OPTIONS := $(foreach opt,$(use_opts),$(call ignore_implicit,$(opt)))
|
||||
BUILD_FEATURES := $(foreach opt,$(patsubst USE_%,%,$(use_opts)),$(if $(USE_$(opt)),+$(opt),-$(opt)))
|
||||
|
||||
# Make a list of all known features with +/- prepended depending on their
|
||||
# activation status. Must be a macro so that dynamically enabled ones are
|
||||
# evaluated with their current status.
|
||||
BUILD_FEATURES = $(foreach opt,$(patsubst USE_%,%,$(use_opts)),$(if $(USE_$(opt)),+$(opt),-$(opt)))
|
||||
|
||||
# All USE_* options have their equivalent macro defined in the code (some might
|
||||
# possibly be unused though)
|
||||
|
Loading…
x
Reference in New Issue
Block a user