diff --git a/mk/llvm.mk b/mk/llvm.mk index 9eb9cc80b6ab8..53775bb85b9d2 100644 --- a/mk/llvm.mk +++ b/mk/llvm.mk @@ -92,11 +92,12 @@ else $$(TROOT$(1)_T_$(2)_H_$(2))/lib/$$(call CFG_LIB_NAME_$(2),LTO): $$(LLVM_CONFIG_$(2)) $$(Q)cp $$(LLVM_LIBDIR_$(2))/$$(call CFG_LIB_NAME_$(2),LTO) $$@ -LLVMgold_NAME_$(2) := $$(shell echo $$(call CFG_LIB_NAME_$(2),LLVMgold) | sed 's/lib//') -$$(TROOT$(1)_T_$(2)_H_$(2))/lib/$$(LLVMgold_NAME_$(2)): $$(LLVM_CONFIG_$(2)) \ +$$(TROOT$(1)_T_$(2)_H_$(2))/lib/$$(shell echo $$(call CFG_LIB_NAME_$(2),LLVMgold) \ + | sed 's/lib//'): $$(LLVM_CONFIG_$(2)) \ $$(TROOT$(1)_T_$(2)_H_$(2))/lib/$$(call CFG_LIB_NAME_$(2),LTO) - $$(Q)cp $$(LLVM_LIBDIR_$(2))/$$(LLVMgold_NAME_$(2)) $$@ + $$(Q)cp $$(LLVM_LIBDIR_$(2))/$$(shell echo $$(call CFG_LIB_NAME_$(2),LLVMgold) \ + | sed 's/lib//') $$@ endif endef diff --git a/mk/main.mk b/mk/main.mk index 901653ae86967..11b00e7f699ea 100644 --- a/mk/main.mk +++ b/mk/main.mk @@ -426,7 +426,7 @@ HSREQ$(1)_H_$(3) = \ tmp/install-debugger-scripts$(1)_H_$(3)-$$(call TRIPLE_TO_DEBUGGER_SCRIPT_SETTING,$(3)).done ifneq (le32-unknown-nacl,$(3)) -HSREQ$(1)_H_$(3) += $$(TROOT$(1)_T_$(3)_H_$(3))/lib/$$(LLVMgold_NAME_$(3)) +HSREQ$(1)_H_$(3) += $$(TROOT$(1)_T_$(3)_H_$(3))/lib/$$(shell echo $$(call CFG_LIB_NAME_$(2),LLVMgold) | sed 's/lib//') endif endif diff --git a/mk/prepare.mk b/mk/prepare.mk index 211050f773bbe..cf19d67e1a13a 100644 --- a/mk/prepare.mk +++ b/mk/prepare.mk @@ -155,7 +155,7 @@ prepare-target-$(2)-host-$(3)-$(1)-$(4): prepare-maybe-clean-$(4) \ $$(call PREPARE_LIB,libcompiler-rt.a) \ $$(if $$(filter $(3),$(2)),\ $$(if $$(findstring nacl,$$(PREPARE_TARGETS)),\ - $$(call PREPARE_LIB,$$(LLVMgold_NAME_$(3))) \ + $$(call PREPARE_LIB,$$(shell echo $$(call CFG_LIB_NAME_$(2),LLVMgold) | sed 's/lib//')) \ $$(call PREPARE_LIB,$$(call CFG_LIB_NAME_$(3),LTO)),),),),),) endef