]> git.ipfire.org Git - thirdparty/haproxy.git/commitdiff
DEV: haring: automatically disable DEBUG_STRICT
authorWilly Tarreau <w@1wt.eu>
Thu, 4 May 2023 06:09:02 +0000 (08:09 +0200)
committerWilly Tarreau <w@1wt.eu>
Thu, 4 May 2023 06:09:02 +0000 (08:09 +0200)
Ideally haring should be compiled with the same options as haproxy so
that ring headers have the same size (e.g. with/without locks, with/
without lock debugging). But when enabling DEBUG_STRICT, BUG_ON() is
enabled and breaks the build by making references to complain() and
ha_backtrace_to_stderr().

Let's just disable DEBUG_STRICT before opening include files. This is
sufficient to address the problem.

This may be backorted to older versions that include haring.

dev/haring/haring.c

index 4b09c9e096d2df387f5fe59a9d0dc2206093bfe5..df455be735a30b0ea9910e1e60ab2775e0578781 100644 (file)
@@ -23,6 +23,8 @@
  * FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR
  * OTHER DEALINGS IN THE SOFTWARE.
  */
+/* we do not implement BUG_ON() */
+#undef DEBUG_STRICT
 
 #include <sys/mman.h>
 #include <sys/stat.h>