From 7668b4bec2f17db78061435697d3dd1c3cfc121b Mon Sep 17 00:00:00 2001 From: Alex Crichton Date: Tue, 29 Mar 2016 09:33:08 -0700 Subject: [PATCH] mk: A few build fixes for i586-pc-windows-msvc Detect the triple in the configure script for probing MSVC shenanigans and also be sure to use `llvm-config` from the build host and not the target when configuring compiler-rt. --- configure | 2 +- mk/rt.mk | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/configure b/configure index 2700a7f6fe0..2a18beeb8c9 100755 --- a/configure +++ b/configure @@ -1252,7 +1252,7 @@ $ pacman -R cmake && pacman -S mingw-w64-x86_64-cmake bits=x86_64 msvc_part=amd64 ;; - i686-*) + i*86-*) bits=i386 msvc_part= ;; diff --git a/mk/rt.mk b/mk/rt.mk index 5f46b3a20c9..590fec53564 100644 --- a/mk/rt.mk +++ b/mk/rt.mk @@ -236,11 +236,11 @@ COMPRT_LIB_$(1) := $$(RT_OUTPUT_DIR_$(1))/$$(COMPRT_NAME_$(1)) COMPRT_BUILD_DIR_$(1) := $$(RT_OUTPUT_DIR_$(1))/compiler-rt ifeq ($$(findstring msvc,$(1)),msvc) -$$(COMPRT_LIB_$(1)): $$(COMPRT_DEPS) $$(MKFILE_DEPS) $$(LLVM_CONFIG_$(1)) +$$(COMPRT_LIB_$(1)): $$(COMPRT_DEPS) $$(MKFILE_DEPS) $$(LLVM_CONFIG_$$(CFG_BUILD)) @$$(call E, cmake: compiler-rt) $$(Q)cd "$$(COMPRT_BUILD_DIR_$(1))"; $$(CFG_CMAKE) "$(S)src/compiler-rt" \ -DCMAKE_BUILD_TYPE=$$(LLVM_BUILD_CONFIG_MODE) \ - -DLLVM_CONFIG_PATH=$$(LLVM_CONFIG_$(1)) \ + -DLLVM_CONFIG_PATH=$$(LLVM_CONFIG_$$(CFG_BUILD)) \ -G"$$(CFG_CMAKE_GENERATOR)" $$(Q)$$(CFG_CMAKE) --build "$$(COMPRT_BUILD_DIR_$(1))" \ --target lib/builtins/builtins \