From effed9df8af7a1e7c94ff63cd02eb44394800d17 Mon Sep 17 00:00:00 2001 From: Tavian Barnes Date: Mon, 23 Mar 2020 13:18:58 -0400 Subject: Makefile: Use --sudo for every distcheck test --- Makefile | 21 ++++++++++----------- 1 file changed, 10 insertions(+), 11 deletions(-) (limited to 'Makefile') diff --git a/Makefile b/Makefile index 5bd8ab8..3ca53af 100644 --- a/Makefile +++ b/Makefile @@ -69,6 +69,10 @@ ALL_CFLAGS = $(ALL_CPPFLAGS) $(LOCAL_CFLAGS) $(CFLAGS) $(DEPFLAGS) ALL_LDFLAGS = $(ALL_CFLAGS) $(LOCAL_LDFLAGS) $(LDFLAGS) ALL_LDLIBS = $(LOCAL_LDLIBS) $(LDLIBS) +ifeq ($(OS),Linux) +DISTCHECK_FLAGS := TEST_FLAGS="--all --sudo" +endif + default: bfs all: bfs tests/mksock @@ -108,21 +112,16 @@ tests/mksock: tests/mksock.o check: check-bfs check-dfs check-ids check-%: all - ./tests.sh --bfs="$(CURDIR)/bfs -S $*" + ./tests.sh --bfs="$(CURDIR)/bfs -S $*" $(TEST_FLAGS) distcheck: - +$(MAKE) -Bs check CFLAGS="$(CFLAGS) $(ASAN_CFLAGS) $(UBSAN_CFLAGS)" + +$(MAKE) -Bs check CFLAGS="$(CFLAGS) $(ASAN_CFLAGS) $(UBSAN_CFLAGS)" $(DISTCHECK_FLAGS) ifneq ($(OS),Darwin) - +$(MAKE) -Bs check CC=clang CFLAGS="$(CFLAGS) $(MSAN_CFLAGS)" - +$(MAKE) -Bs check CFLAGS="$(CFLAGS) -m32" -endif - +$(MAKE) -Bs release check - +$(MAKE) -Bs check -ifeq ($(OS),Linux) - ./tests.sh --sudo --bfs="$(CURDIR)/bfs" - ./tests.sh --sudo --bfs="$(CURDIR)/bfs -S dfs" - ./tests.sh --sudo --bfs="$(CURDIR)/bfs -S ids" + +$(MAKE) -Bs check CC=clang CFLAGS="$(CFLAGS) $(MSAN_CFLAGS)" $(DISTCHECK_FLAGS) + +$(MAKE) -Bs check CFLAGS="$(CFLAGS) -m32" $(DISTCHECK_FLAGS) endif + +$(MAKE) -Bs release check $(DISTCHECK_FLAGS) + +$(MAKE) -Bs check $(DISTCHECK_FLAGS) clean: $(RM) bfs *.[od] tests/mksock tests/*.[od] -- cgit v1.2.3