mirror of
git://git.sv.gnu.org/emacs.git
synced 2025-12-06 06:20:55 -08:00
Better support for parallel make
* mps/code/comm.gmk (LIB_TARGETS, TEST_TARGETS, EVENT_TARGETS) (TEST_SUITES, testmmqa): If VARIETY is not defined, then disable parallism with .NOTPARALLEL. Otherwise, avoid the recursive make with a static pattern rule. (clean-testansi, clean-testpollnone): New. * mps/Makefile.in (build-via-make): Invoke submake explicit VARIETY argument to allow more parallelism. (test-make-build): Use clean-testansi and clean-testpollnone.
This commit is contained in:
parent
d15aa6aa44
commit
a97f6d888f
2 changed files with 11 additions and 7 deletions
|
|
@ -34,7 +34,8 @@ XCODEBUILD=xcrun xcodebuild -project code/mps.xcodeproj
|
||||||
all: @BUILD_TARGET@
|
all: @BUILD_TARGET@
|
||||||
|
|
||||||
build-via-make:
|
build-via-make:
|
||||||
$(MAKE) $(TARGET_OPTS)
|
$(MAKE) $(TARGET_OPTS) VARIETY=cool
|
||||||
|
$(MAKE) $(TARGET_OPTS) VARIETY=hot
|
||||||
|
|
||||||
clean-make-build:
|
clean-make-build:
|
||||||
$(MAKE) $(TARGET_OPTS) clean
|
$(MAKE) $(TARGET_OPTS) clean
|
||||||
|
|
@ -84,12 +85,12 @@ test-make-build:
|
||||||
$(MAKE) -C code -f anan$(MPS_BUILD_NAME).gmk VARIETY=cool \
|
$(MAKE) -C code -f anan$(MPS_BUILD_NAME).gmk VARIETY=cool \
|
||||||
CC='$(CC)' \
|
CC='$(CC)' \
|
||||||
CFLAGSCOMPILERSTRICT='$(CFLAGSCOMPILERSTRICT)' \
|
CFLAGSCOMPILERSTRICT='$(CFLAGSCOMPILERSTRICT)' \
|
||||||
clean testansi
|
clean-testansi
|
||||||
$(MAKE) -C code -f anan$(MPS_BUILD_NAME).gmk VARIETY=cool \
|
$(MAKE) -C code -f anan$(MPS_BUILD_NAME).gmk VARIETY=cool \
|
||||||
CC='$(CC)' \
|
CC='$(CC)' \
|
||||||
CFLAGS="-DCONFIG_POLL_NONE" \
|
CFLAGS="-DCONFIG_POLL_NONE" \
|
||||||
CFLAGSCOMPILERSTRICT='$(CFLAGSCOMPILERSTRICT)' \
|
CFLAGSCOMPILERSTRICT='$(CFLAGSCOMPILERSTRICT)' \
|
||||||
clean testpollnone
|
clean-testpollnone
|
||||||
|
|
||||||
test-xcode-build:
|
test-xcode-build:
|
||||||
$(XCODEBUILD) -config Debug -target testci
|
$(XCODEBUILD) -config Debug -target testci
|
||||||
|
|
|
||||||
|
|
@ -363,13 +363,18 @@ testscheme: phony
|
||||||
# These convenience targets allow one to type "make foo" to build target
|
# These convenience targets allow one to type "make foo" to build target
|
||||||
# foo in selected varieties (or none, for the latter rule).
|
# foo in selected varieties (or none, for the latter rule).
|
||||||
|
|
||||||
$(LIB_TARGETS) $(TEST_TARGETS) $(EVENT_TARGETS) $(TEST_SUITES) testmmqa: phony
|
|
||||||
ifdef VARIETY
|
ifdef VARIETY
|
||||||
$(MAKE) -f $(PFM).gmk TARGET=$@ variety
|
$(LIB_TARGETS) $(TEST_TARGETS) $(EVENT_TARGETS) $(TEST_SUITES) testmmqa: \
|
||||||
|
%: $(PFM)/$(VARIETY)/% ;
|
||||||
else
|
else
|
||||||
|
$(LIB_TARGETS) $(TEST_TARGETS) $(EVENT_TARGETS) $(TEST_SUITES) testmmqa:
|
||||||
$(MAKE) -f $(PFM).gmk TARGET=$@ target
|
$(MAKE) -f $(PFM).gmk TARGET=$@ target
|
||||||
|
.NOTPARALLEL:
|
||||||
endif
|
endif
|
||||||
|
|
||||||
|
# Targets for toplevel make
|
||||||
|
clean-testansi: clean .WAIT testansi
|
||||||
|
clean-testpollnone: clean .WAIT testpollnone
|
||||||
|
|
||||||
# "clean" removes the directory containing the build results for the
|
# "clean" removes the directory containing the build results for the
|
||||||
# platform.
|
# platform.
|
||||||
|
|
@ -611,14 +616,12 @@ endif
|
||||||
|
|
||||||
define run-cc-strict
|
define run-cc-strict
|
||||||
$(ECHO) "$(PFM): $@"
|
$(ECHO) "$(PFM): $@"
|
||||||
mkdir -p $(PFM)
|
|
||||||
mkdir -p $(PFM)/$(VARIETY)
|
mkdir -p $(PFM)/$(VARIETY)
|
||||||
$(CC) $(CFLAGSSTRICT) -c -o $@ $<
|
$(CC) $(CFLAGSSTRICT) -c -o $@ $<
|
||||||
endef
|
endef
|
||||||
|
|
||||||
define run-cc-lax
|
define run-cc-lax
|
||||||
$(ECHO) "$(PFM): $@ - compiling with lax flags."
|
$(ECHO) "$(PFM): $@ - compiling with lax flags."
|
||||||
mkdir -p $(PFM)
|
|
||||||
mkdir -p $(PFM)/$(VARIETY)
|
mkdir -p $(PFM)/$(VARIETY)
|
||||||
$(CC) $(CFLAGSLAX) -c -o $@ $<
|
$(CC) $(CFLAGSLAX) -c -o $@ $<
|
||||||
endef
|
endef
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue