Skip to content

Commit 44be4a4

Browse files
committed
Move the llvm auto-clean stamp into $target/llvm
1 parent 1fbbc71 commit 44be4a4

File tree

2 files changed

+12
-11
lines changed

2 files changed

+12
-11
lines changed

Makefile.in

Lines changed: 1 addition & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -574,19 +574,10 @@ ALL_TARGET_RULES = $(foreach target,$(CFG_TARGET_TRIPLES), \
574574
$(foreach host,$(CFG_HOST_TRIPLES), \
575575
all-target-$(target)-host-$(host)))
576576

577-
all: rustllvm/llvm-auto-clean-stamp \
578-
$(ALL_TARGET_RULES) $(GENERATED) docs
577+
all: $(ALL_TARGET_RULES) $(GENERATED) docs
579578

580579
endif
581580

582-
# This is used to independently force an LLVM clean rebuild
583-
# when we changed something not otherwise captured by builtin
584-
# dependencies. In these cases, commit a change that touches
585-
# the stamp in the source dir.
586-
rustllvm/llvm-auto-clean-stamp: $(S)src/rustllvm/llvm-auto-clean-trigger
587-
$(Q)$(MAKE) clean-llvm
588-
touch $@
589-
590581

591582
######################################################################
592583
# Re-configuration

mk/llvm.mk

Lines changed: 11 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,12 +24,22 @@ define DEF_LLVM_RULES
2424
# If CFG_LLVM_ROOT is defined then we don't build LLVM ourselves
2525
ifeq ($(CFG_LLVM_ROOT),)
2626

27-
$$(LLVM_CONFIG_$(1)): $$(LLVM_DEPS)
27+
LLVM_STAMP_$(1) = $$(CFG_LLVM_BUILD_DIR_$(1))/llvm-auto-clean-stamp
28+
29+
$$(LLVM_CONFIG_$(1)): $$(LLVM_DEPS) $$(LLVM_STAMP_$(1))
2830
@$$(call E, make: llvm)
2931
$$(Q)$$(MAKE) -C $$(CFG_LLVM_BUILD_DIR_$(1)) $$(CFG_LLVM_BUILD_ENV)
3032
$$(Q)touch $$(LLVM_CONFIG_$(1))
3133
endif
3234

35+
# This is used to independently force an LLVM clean rebuild
36+
# when we changed something not otherwise captured by builtin
37+
# dependencies. In these cases, commit a change that touches
38+
# the stamp in the source dir.
39+
$$(LLVM_STAMP_$(1)): $(S)src/rustllvm/llvm-auto-clean-trigger
40+
$(Q)$(MAKE) clean-llvm
41+
touch $$@
42+
3343
endef
3444

3545
$(foreach host,$(CFG_HOST_TRIPLES), \

0 commit comments

Comments
 (0)