Use .NOTPARALLEL in posix.mak instead of lockfiles in build.d

They achieve the same behaviour as `posix.mak` simply forwards to build.d.

This is a workaround for https://issues.dlang.org/show_bug.cgi?id=20999
which seems to be caused by some local library based on these observations:

- the failure is restricted to the macair host, no failures
  on D-Autotester.local
- the failure happens upon the second invocation of build.d
- removing `--called-from-make` makes the errror disappear.
  This switch enables a lockfile (`generated/build.lock`) which ensures
  that mutliple instances of build.d are run mutually exclusive (this
  was required during the `make` -> build.d transition but is obsolete now)
This commit is contained in:
MoonlightSentinel 2020-08-05 17:06:45 +02:00 committed by The Dlang Bot
parent 491c044710
commit 7ec7deaa9c
2 changed files with 11 additions and 2 deletions

View file

@ -76,3 +76,8 @@ style:
$(QUIET)$(MAKE) -C src -f posix.mak style $(QUIET)$(MAKE) -C src -f posix.mak style
.DELETE_ON_ERROR: # GNU Make directive (delete output files on error) .DELETE_ON_ERROR: # GNU Make directive (delete output files on error)
# Dont run targets in parallel because this makefile is just a thin wrapper
# for build.d and multiple invocations might stomp on each other.
# (build.d employs it's own parallelization)
.NOTPARALLEL:

View file

@ -92,8 +92,7 @@ ifeq (,$(HOST_DMD_PATH))
endif endif
HOST_DMD_RUN:=$(HOST_DMD) HOST_DMD_RUN:=$(HOST_DMD)
RUN_BUILD = $(GENERATED)/build HOST_DMD="$(HOST_DMD)" CXX="$(HOST_CXX)" OS=$(OS) BUILD=$(BUILD) MODEL=$(MODEL) AUTO_BOOTSTRAP="$(AUTO_BOOTSTRAP)" DOCDIR="$(DOCDIR)" STDDOC="$(STDDOC)" DOC_OUTPUT_DIR="$(DOC_OUTPUT_DIR)" MAKE="$(MAKE)" --called-from-make RUN_BUILD = $(GENERATED)/build HOST_DMD="$(HOST_DMD)" CXX="$(HOST_CXX)" OS=$(OS) BUILD=$(BUILD) MODEL=$(MODEL) AUTO_BOOTSTRAP="$(AUTO_BOOTSTRAP)" DOCDIR="$(DOCDIR)" STDDOC="$(STDDOC)" DOC_OUTPUT_DIR="$(DOC_OUTPUT_DIR)" MAKE="$(MAKE)"
######## Begin build targets ######## Begin build targets
all: dmd all: dmd
@ -200,4 +199,9 @@ endif
.DELETE_ON_ERROR: # GNU Make directive (delete output files on error) .DELETE_ON_ERROR: # GNU Make directive (delete output files on error)
# Dont run targets in parallel because this makefile is just a thin wrapper
# for build.d and multiple invocations might stomp on each other.
# (build.d employs it's own parallelization)
.NOTPARALLEL:
endif endif