aboutsummaryrefslogtreecommitdiff
path: root/debian/rules
diff options
context:
space:
mode:
authorBen Pfaff <blp@nicira.com>2011-03-14 15:11:39 -0700
committerBen Pfaff <blp@nicira.com>2011-03-14 15:14:01 -0700
commita1b3608fab2c00c022cdd3090d5acde83d610574 (patch)
tree22d173bafc4c6720fd41657c45f34ac45f91d01f /debian/rules
parent0aae40a52817ff2644dea8003b3a542228369f6a (diff)
debian: Run tests in parallel too.
Passing e.g. -j4 in TESTSUITEFLAGS runs 4 tests in parallel, which speeds up the testsuite.
Diffstat (limited to 'debian/rules')
-rwxr-xr-xdebian/rules9
1 files changed, 6 insertions, 3 deletions
diff --git a/debian/rules b/debian/rules
index bbc7357e..de79800a 100755
--- a/debian/rules
+++ b/debian/rules
@@ -14,9 +14,11 @@
BUILD_NUMBER = 0
ifneq (,$(filter parallel=%,$(DEB_BUILD_OPTIONS)))
-NUMJOBS = $(patsubst parallel=%,%,$(filter parallel=%,$(DEB_BUILD_OPTIONS)))
-MAKEFLAGS += -j$(NUMJOBS)
+PARALLEL = -j$(patsubst parallel=%,%,$(filter parallel=%,$(DEB_BUILD_OPTIONS)))
+else
+PARALLEL =
endif
+MAKEFLAGS += $(PARALLEL)
ifneq (,$(filter noopt,$(DEB_BUILD_OPTIONS)))
CFLAGS += -O0
@@ -45,7 +47,8 @@ build-arch: build-arch-stamp
build-arch-stamp: configure-stamp
$(MAKE) -C _debian
ifeq (,$(filter nocheck,$(DEB_BUILD_OPTIONS)))
- if $(MAKE) -C _debian check; then :; else \
+ if $(MAKE) -C _debian check TESTSUITEFLAGS='$(PARALLEL)'; then :; \
+ else \
cat _debian/tests/testsuite.log; \
exit 1; \
fi