From b8e7c4fcb9655ff92f8f2feba4ba4221646acc6f Mon Sep 17 00:00:00 2001 From: Brian Anderson Date: Wed, 29 Oct 2014 19:54:52 -0700 Subject: [PATCH] mk: Clean just one llvm build at a time. Closes #17852 When building for multiple targets, the initial 'make' invocation always fails. The missing build stamp causes clean-llvm to be invoked, but clean-llvm cleans *all* llvm builds. So what happens is that 1) all llvm's are cleaned (a no-op), 2) llvm-${target1} builds, 3) all llvm's are cleaned (deleting llvm-${target1}), 4) llvm-${target2} is built, 5) the remaining build for ${target1} fails because llvm does not exist. This makes the clean operation only clean the correct llvm build. Should greatly reduce bot failures. --- mk/llvm.mk | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/mk/llvm.mk b/mk/llvm.mk index 177e4de310324..bce4390205626 100644 --- a/mk/llvm.mk +++ b/mk/llvm.mk @@ -38,7 +38,7 @@ endif # the stamp in the source dir. $$(LLVM_STAMP_$(1)): $(S)src/rustllvm/llvm-auto-clean-trigger @$$(call E, make: cleaning llvm) - $(Q)$(MAKE) clean-llvm + $(Q)$(MAKE) clean-llvm$(1) @$$(call E, make: done cleaning llvm) touch $$@