]> git.kaiwu.me - haproxy.git/commitdiff
BUILD: makefile: add macros enable_opts and disable_opts
authorWilly Tarreau <w@1wt.eu>
Thu, 21 May 2026 07:24:45 +0000 (09:24 +0200)
committerWilly Tarreau <w@1wt.eu>
Fri, 3 Jul 2026 14:33:27 +0000 (16:33 +0200)
These ones are used to only enable or disable selected options.

include/make/options.mk

index 75c84e605b4e99d27b26198db5f331e5271ffc84..87d82788f62de65e279816fc9b975f06d7dabe21 100644 (file)
@@ -8,6 +8,12 @@
 # there unless you're adding support for a new platform.
 default_opts = $(foreach name,$(1),$(eval $(name)=implicit))
 
+# Disables all specified options
+disable_opts = $(foreach name,$(1),$(eval $(name)=0))
+
+# Enables all specified options
+enable_opts = $(foreach name,$(1),$(eval $(name)=1))
+
 # Return USE_xxx=$(USE_xxx) if the variable was set from the environment or the
 # command line.
 ignore_implicit = $(if $(subst environment,,$(origin $(1))),         \