|
From: | Frederik Seiffert |
Subject: | Re: Building GNUstep for Windows using Clang |
Date: | Fri, 15 May 2020 10:00:22 +0200 |
Hi all, Following up on this thread I wanted to give a quick update on building GNUstep for Windows. First, I managed to build Base successfully using GCC on MinGW 64-bit following Riccardo’s helpful instructions at http://wiki.gnustep.org/index.php/Installation_MSYS2. Two small things here (I can’t edit the wiki, so would be great if someone could add these): 1. The build instructions for Make are obviously missing a "make install" step. 2. I also had to install the following packages for ICU: - mingw64/mingw-w64-x86_64-icu - msys/icu-devel I did not have to patch the MSYS2 headers as written in the instructions, but maybe that’s only needed for Gui? It does show a lot of warnings during build, some of which look somewhat concerning. If I find some time I’ll try to add a Windows OS target to the Travis setup to run the tests and ensure this is kept working. As a side note, Make doesn’t seem to handle spaces in the home directory correctly – does someone know where to fix this?
Moving on to building with Clang and libobjc2, as mentioned in an earlier message to this thread, I first built libobjc2 in a Visual Studio command prompt using CMake and clang-cl, which according to David is the way to go. I’ve then been trying two approaches for building GNUstep: 1. Using MinGW 32/64-bit, and setting CC/CXX env vars to Clang: I have not been able to get this to work at all so far, as I can’t figure out how to change the linker to LLD or ld.gold, as required for this setup. Neither setting LD=lld or LDFLAGS="-fuse-ld=lld" or "=gold" seems to have any effect. Calling "clang --print-prog-name=ld" (which is what Make does to check which linker is being used) will always output ld. I’m probably missing something here – can anyone point me in the right direction how to change the linker? 2. Using the llvm-mingw toolchain (https://github.com/mstorsjo/llvm-mingw), which is preconfigured to use LLD: This goes pretty far (after a couple fixes I pushed yesterday), but in the end fails for me with the following:
I’d appreciate any thoughts on the above. Thanks! Frederik |
[Prev in Thread] | Current Thread | [Next in Thread] |