BUILD: debug: make DEBUG_STRICT=1 the default

We continue to carry it in the makefile, which adds to the difficulty
of passing new options. Let's make DEBUG_STRICT=1 the default so that
one has to explicitly pass DEBUG_STRICT=0 to disable it. This allows us
to remove the option from the default DEBUG variable in the makefile.
This commit is contained in:
Willy Tarreau 2024-04-10 09:02:28 +02:00
parent b22b968a48
commit b70981532a
3 changed files with 8 additions and 3 deletions

View File

@ -658,8 +658,8 @@ these options should not be changed. Among the usable ones are:
conditions are not met, and whose violation will result in a misbehaving
process due to memory corruption or other significant trouble, possibly
caused by an attempt to exploit a bug in the program or a library it relies
on. The option knows 3 values: 0 (disable all such assertions, the default
when the option is not set), 1 (enable all inexpensive assertions), and
on. The option knows 3 values: 0 (disable all such assertions, not
recommended), 1 (enable all inexpensive assertions, the default), and
2 (enable all assertions even in fast paths). Setting the option with no
value corresponds to 1, which is the recommended value for production.

View File

@ -228,7 +228,7 @@ SMALL_OPTS =
# DEBUG_NO_POOLS, DEBUG_FAIL_ALLOC, DEBUG_STRICT_ACTION=[0-3], DEBUG_HPACK,
# DEBUG_AUTH, DEBUG_SPOE, DEBUG_UAF, DEBUG_THREAD, DEBUG_STRICT, DEBUG_DEV,
# DEBUG_TASK, DEBUG_MEMORY_POOLS, DEBUG_POOL_TRACING, DEBUG_QPACK, DEBUG_LIST.
DEBUG = -DDEBUG_STRICT -DDEBUG_MEMORY_POOLS
DEBUG = -DDEBUG_MEMORY_POOLS
#### Trace options
# Use TRACE=1 to trace function calls to file "trace.out" or to stderr if not

View File

@ -556,4 +556,9 @@
# define RING_DFLT_QUEUES 6
#endif
/* Let's make DEBUG_STRICT default to 1 to get rid of it in the makefile */
#ifndef DEBUG_STRICT
# define DEBUG_STRICT 1
#endif
#endif /* _HAPROXY_DEFAULTS_H */