Skip to content

Commit 49b751d

Browse files
committed
auto merge of #10850 : alexcrichton/rust/fix-target, r=pcwalton
Right now multiple targets/hosts is broken because the libdir passed for all of the LLVM libraries is for the wrong architecture. By using the right arch (target, not host), everything is linked and assembled just fine.
2 parents 67aca9c + f04d624 commit 49b751d

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

mk/target.mk

+1-1
Original file line numberDiff line numberDiff line change
@@ -130,7 +130,7 @@ $$(TLIB$(1)_T_$(2)_H_$(3))/$(CFG_LIBRUSTC_$(3)): \
130130
$$(call REMOVE_ALL_OLD_GLOB_MATCHES_EXCEPT,$$(dir $$@),$(LIBRUSTC_GLOB_$(2)),$$(notdir $$@))
131131
$$(call REMOVE_ALL_OLD_GLOB_MATCHES_EXCEPT,$$(dir $$@),$(LIBRUSTC_RGLOB_$(2)),$$(notdir $$@))
132132
$$(STAGE$(1)_T_$(2)_H_$(3)) $$(WFLAGS_ST$(1)) \
133-
-L "$$(LLVM_LIBDIR_$(3))" \
133+
-L "$$(LLVM_LIBDIR_$(2))" \
134134
--out-dir $$(@D) $$< && touch $$@
135135
$$(call LIST_ALL_OLD_GLOB_MATCHES_EXCEPT,$$(dir $$@),$(LIBRUSTC_GLOB_$(2)),$$(notdir $$@))
136136
$$(call LIST_ALL_OLD_GLOB_MATCHES_EXCEPT,$$(dir $$@),$(LIBRUSTC_RGLOB_$(2)),$$(notdir $$@))

mk/tests.mk

+1-1
Original file line numberDiff line numberDiff line change
@@ -377,7 +377,7 @@ $(3)/stage$(1)/test/rustctest-$(2)$$(X_$(2)): \
377377
$$(TLIB$(1)_T_$(2)_H_$(3))/$$(CFG_LIBSYNTAX_$(2))
378378
@$$(call E, compile_and_link: $$@)
379379
$$(STAGE$(1)_T_$(2)_H_$(3)) -o $$@ $$< --test \
380-
-L "$$(LLVM_LIBDIR_$(3))"
380+
-L "$$(LLVM_LIBDIR_$(2))"
381381

382382
$(3)/stage$(1)/test/rustpkgtest-$(2)$$(X_$(2)): \
383383
$$(RUSTPKG_LIB) $$(RUSTPKG_INPUTS) \

0 commit comments

Comments
 (0)