]> git.ipfire.org Git - thirdparty/haproxy.git/commit
MINOR: haproxy: permit to register features during boot
authorWilly Tarreau <w@1wt.eu>
Fri, 6 Oct 2023 08:45:16 +0000 (10:45 +0200)
committerWilly Tarreau <w@1wt.eu>
Fri, 6 Oct 2023 09:40:02 +0000 (11:40 +0200)
commit90fa2eaa1563f22fe300c4aa4355c6fdbfec19c3
tree630f78f97971284b7131a372e198fb25c969d9f2
parenta5e96425a2819959fe2c6cffcec392beb858dd2c
MINOR: haproxy: permit to register features during boot

The regtests are using the "feature()" predicate but this one can only
rely on build-time options. It would be nice if some runtime-specific
options could be detected at boot time so that regtests could more
flexibly adapt to what is supported (capabilities, splicing, etc).

Similarly, certain features that are currently enabled with USE_XXX
could also be automatically detected at build time using ifdefs and
would simplify the configuration, but then we'd lose the feature
report in the feature list which is convenient for regtests.

This patch makes sure that haproxy -vv shows the variable's contents
and not the macro's contents, and adds a new hap_register_feature()
to allow the code to register a new keyword.
include/haproxy/global.h
src/haproxy.c