summaryrefslogtreecommitdiffstats
path: root/Makefile
diff options
context:
space:
mode:
authorTavian Barnes <tavianator@tavianator.com>2020-03-23 13:18:58 -0400
committerTavian Barnes <tavianator@tavianator.com>2020-03-23 13:29:03 -0400
commiteffed9df8af7a1e7c94ff63cd02eb44394800d17 (patch)
treea421e2285d5dab1630c0498589a686cb3a602186 /Makefile
parent12e93e7c7721f9a581f62a8df9534571d0ec353d (diff)
downloadbfs-effed9df8af7a1e7c94ff63cd02eb44394800d17.tar.xz
Makefile: Use --sudo for every distcheck test
Diffstat (limited to 'Makefile')
-rw-r--r--Makefile21
1 files changed, 10 insertions, 11 deletions
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]