From 5c643f37d0ba3390b35332453ab97b4d1a24e2ab Mon Sep 17 00:00:00 2001 From: Willy Tarreau Date: Thu, 22 Oct 2020 05:12:57 +0200 Subject: [PATCH] BUILD: makefile: add entries to build common debugging tools A few tools in contrib/ such as halog, flags, poll and tcploop are occasionally useful at least to developers, and some of them such as halog or flags can occasionally break due to some changes in the include files. As reported in issue #907, their inability to inherit the global build options also causes some warnings related to some specificities of the main include files. Let's just add entries in the main makefile to build them. --- Makefile | 13 +++++++++++++ 1 file changed, 13 insertions(+) diff --git a/Makefile b/Makefile index 2fb05c719..85ca45e43 100644 --- a/Makefile +++ b/Makefile @@ -888,6 +888,18 @@ objsize: haproxy %.o: %.c $(DEP) $(cmd_CC) $(COPTS) -c -o $@ $< +contrib/halog/halog: + $(Q)$(MAKE) -C contrib/halog halog CC='$(cmd_CC)' OPTIMIZE='$(COPTS)' + +contrib/debug/flags: + $(Q)$(MAKE) -C contrib/debug flags CC='$(cmd_CC)' OPTIMIZE='$(COPTS)' + +contrib/debug/poll: + $(Q)$(MAKE) -C contrib/debug poll CC='$(cmd_CC)' OPTIMIZE='$(COPTS)' + +contrib/tcploop/tcploop: + $(Q)$(MAKE) -C contrib/tcploop tcploop CC='$(cmd_CC)' OPTIMIZE='$(COPTS)' + # rebuild it every time .PHONY: src/version.c @@ -943,6 +955,7 @@ clean: $(Q)for dir in . src include/* doc; do rm -f $$dir/*~ $$dir/*.rej $$dir/core; done $(Q)rm -f haproxy-$(VERSION).tar.gz haproxy-$(VERSION)$(SUBVERS)$(EXTRAVERSION).tar.gz $(Q)rm -f haproxy-$(VERSION) haproxy-$(VERSION)$(SUBVERS)$(EXTRAVERSION) nohup.out gmon.out + $(Q)rm -f contrib/halog/halog contrib/debug/flags contrib/debug/poll contrib/tcploop/tcploop tags: $(Q)find src include \( -name '*.c' -o -name '*.h' \) -print0 | \