[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
.NOTPARALLEL as a dependency
From: |
Ed Hutchins |
Subject: |
.NOTPARALLEL as a dependency |
Date: |
Mon, 21 Oct 2013 17:43:29 -0700 |
I'm using a complex non-recursive make system to run test suites, some
subset of which are performance tests which should not run in
parallel.
Is there any way to get gmake to run a job serially? Ideally something like:
mytarget: .NOTPARALLEL
Currently I'm forced to either break up the test suite rules and run
the perf tests separately, or do something really ugly like:
EMPTY :=
COMMA := ,
SPACE := $(EMPTY) $(EMPTY)
# macros to get the job descriptor FDs
JSFDS = $(patsubst --jobserver-fds=%,%,$(filter --jobserver-fds=%,$(MAKEFLAGS)))
RJSFD = $(firstword $(subst $(COMMA),$(SPACE),$(JSFDS)))
WJSFD = $(lastword $(subst $(COMMA),$(SPACE),$(JSFDS)))
holdjobs:
+read -N7 -u$(RJSFD)
freejobs: $(ALLTS)
+echo -n '+++++++' >&$(WJSFD)
$(SERIAL_TESTS): holdjobs
freejobs: $(SERIAL_TESTS)
serialized_tests: $(SERIAL_TESTS) freejobs
(the above works only for -j8, for example). As an aside is there any
way to determine the original -jN argument?
- Ed
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- .NOTPARALLEL as a dependency,
Ed Hutchins <=