From 6be2c5a7e9187fc14d51e1ec32ca235143bb0d8b Mon Sep 17 00:00:00 2001 From: Ben Gamari Date: Fri, 14 Jan 2022 19:56:05 -0500 Subject: Windows/Clang: Build system adaptation * Bump win32-tarballs to 0.7 * Move Windows toolchain autoconf logic into separate file * Use clang and LLVM utilities as described in #21019 * Disable object merging as lld doesn't support -r * Drop --oformat=pe-bigobj-x86-64 arguments from ld flags as LLD detects that the output is large on its own. * Drop gcc wrapper since Clang finds its root fine on its own. --- mk/config.mk.in | 12 ++---------- mk/get-win32-tarballs.py | 2 +- 2 files changed, 3 insertions(+), 11 deletions(-) (limited to 'mk') diff --git a/mk/config.mk.in b/mk/config.mk.in index 06e1dabd96..e1474a34a3 100644 --- a/mk/config.mk.in +++ b/mk/config.mk.in @@ -655,11 +655,7 @@ SRC_HSC2HS_OPTS_STAGE0 += --cflag=-D$(HostArch_CPP)_HOST_ARCH --cflag=-D$(HostOS SRC_HSC2HS_OPTS_STAGE1 += --cflag=-D$(TargetArch_CPP)_HOST_ARCH --cflag=-D$(TargetOS_CPP)_HOST_OS SRC_HSC2HS_OPTS_STAGE2 += --cflag=-D$(TargetArch_CPP)_HOST_ARCH --cflag=-D$(TargetOS_CPP)_HOST_OS -ifeq "$(TARGETPLATFORM)" "i386-unknown-mingw32" -WINDRES = $(INPLACE_MINGW)/bin/windres -else ifeq "$(TARGETPLATFORM)" "x86_64-unknown-mingw32" -WINDRES = $(INPLACE_MINGW)/bin/windres -endif +WINDRES=@WindresCmd@ #----------------------------------------------------------------------------- # Python for testsuite driver and code generators @@ -670,11 +666,7 @@ PYTHON=@PythonCmd@ # Mingwex Library # HaveLibMingwEx = @HaveLibMingwEx@ -ifeq "$(TARGETPLATFORM)" "i386-unknown-mingw32" -DLLTOOL = inplace/mingw/bin/dlltool.exe -else ifeq "$(TARGETPLATFORM)" "x86_64-unknown-mingw32" -DLLTOOL = inplace/mingw/bin/dlltool.exe -endif +DLLTOOL = @DlltoolCmd@ #----------------------------------------------------------------------------- # Other standard (ha!) Unix utilities diff --git a/mk/get-win32-tarballs.py b/mk/get-win32-tarballs.py index f1ada96b48..351212ba71 100755 --- a/mk/get-win32-tarballs.py +++ b/mk/get-win32-tarballs.py @@ -8,7 +8,7 @@ import argparse import sys from sys import stderr -TARBALL_VERSION = '0.3' +TARBALL_VERSION = '0.7' BASE_URL = "https://downloads.haskell.org/ghc/mingw/{}".format(TARBALL_VERSION) DEST = Path('ghc-tarballs/mingw-w64') ARCHS = ['i686', 'x86_64', 'sources'] -- cgit v1.2.1