From d9218abc7148481292508b76929e7f6286af1718 Mon Sep 17 00:00:00 2001 From: Matthew Flatt Date: Thu, 13 Sep 2018 07:42:18 -0600 Subject: [PATCH] makefile: add `CPUS` support to the `cs` target --- Makefile | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/Makefile b/Makefile index 4407dcbf0a..9e3fba7cfc 100644 --- a/Makefile +++ b/Makefile @@ -235,12 +235,20 @@ BASE_TARGET = plain-minimal-in-place CS_SETUP_TARGET = plain-in-place-after-base cs: + if [ "$(CPUS)" = "" ] ; \ + then $(MAKE) plain-cs ; \ + else $(MAKE) cpus-cs CPUS="$(CPUS)" ; fi + +plain-cs: if [ "$(SCHEME_SRC)" = "" ] ; \ then $(MAKE) scheme-src ; fi if [ "$(RACKET)" = "" ] ; \ then $(MAKE) racket-then-cs ; \ else $(MAKE) cs-after-racket-with-racket RACKET="$(RACKET)" ; fi +cpus-cs: + $(MAKE) -j $(CPUS) plain-cs JOB_OPTIONS="-j $(CPUS)" + cs-in-place: $(MAKE) cs