forked from M-Labs/nac3
README,nix: remove lld
This commit is contained in:
parent
50ed04b787
commit
33321c5e9c
@ -36,12 +36,6 @@ pacman -Syu
|
|||||||
pacman -S mingw-w64-x86_64-artiq
|
pacman -S mingw-w64-x86_64-artiq
|
||||||
```
|
```
|
||||||
|
|
||||||
Install ``lld-msys2`` manually:
|
|
||||||
```
|
|
||||||
wget https://nixbld.m-labs.hk/build/115527/download/1/ld.lld.exe
|
|
||||||
mv ld.lld.exe C:/msys64/mingw64/bin
|
|
||||||
```
|
|
||||||
|
|
||||||
Note: This build of NAC3 cannot be used with Anaconda Python nor the python.org binaries for Windows. Those Python versions are compiled with Visual Studio (MSVC) and their ABI is incompatible with the GNU ABI used in this build. We have no plans to support Visual Studio nor the MSVC ABI. If you need a MSVC build, please install the requisite bloated spyware from Microsoft and compile NAC3 yourself.
|
Note: This build of NAC3 cannot be used with Anaconda Python nor the python.org binaries for Windows. Those Python versions are compiled with Visual Studio (MSVC) and their ABI is incompatible with the GNU ABI used in this build. We have no plans to support Visual Studio nor the MSVC ABI. If you need a MSVC build, please install the requisite bloated spyware from Microsoft and compile NAC3 yourself.
|
||||||
|
|
||||||
## For developers
|
## For developers
|
||||||
|
@ -97,7 +97,6 @@
|
|||||||
];
|
];
|
||||||
buildInputs = [
|
buildInputs = [
|
||||||
(python3-mimalloc.withPackages(ps: [ ps.numpy ps.jsonschema nac3artiq-instrumented ]))
|
(python3-mimalloc.withPackages(ps: [ ps.numpy ps.jsonschema nac3artiq-instrumented ]))
|
||||||
pkgs.lld_14
|
|
||||||
pkgs.llvmPackages_14.llvm.out
|
pkgs.llvmPackages_14.llvm.out
|
||||||
];
|
];
|
||||||
phases = [ "buildPhase" "installPhase" ];
|
phases = [ "buildPhase" "installPhase" ];
|
||||||
@ -152,7 +151,7 @@
|
|||||||
cargo
|
cargo
|
||||||
rustc
|
rustc
|
||||||
# runtime dependencies
|
# runtime dependencies
|
||||||
lld_14
|
lld_14 # for running kernels on the host
|
||||||
(packages.x86_64-linux.python3-mimalloc.withPackages(ps: [ ps.numpy ]))
|
(packages.x86_64-linux.python3-mimalloc.withPackages(ps: [ ps.numpy ]))
|
||||||
# development tools
|
# development tools
|
||||||
cargo-insta
|
cargo-insta
|
||||||
@ -175,7 +174,6 @@
|
|||||||
llvm-nac3-msys2 = packages.x86_64-w64-mingw32.llvm-nac3;
|
llvm-nac3-msys2 = packages.x86_64-w64-mingw32.llvm-nac3;
|
||||||
nac3artiq-msys2 = packages.x86_64-w64-mingw32.nac3artiq;
|
nac3artiq-msys2 = packages.x86_64-w64-mingw32.nac3artiq;
|
||||||
nac3artiq-msys2-pkg = packages.x86_64-w64-mingw32.nac3artiq-pkg;
|
nac3artiq-msys2-pkg = packages.x86_64-w64-mingw32.nac3artiq-pkg;
|
||||||
lld-msys2 = packages.x86_64-w64-mingw32.lld;
|
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|
||||||
|
@ -126,43 +126,6 @@ in rec {
|
|||||||
echo file msys2 $out/*.pkg.tar.zst >> $out/nix-support/hydra-build-products
|
echo file msys2 $out/*.pkg.tar.zst >> $out/nix-support/hydra-build-products
|
||||||
'';
|
'';
|
||||||
};
|
};
|
||||||
lld = pkgs.stdenvNoCC.mkDerivation rec {
|
|
||||||
pname = "lld-msys2";
|
|
||||||
version = "14.0.4";
|
|
||||||
src = pkgs.fetchurl {
|
|
||||||
url = "https://github.com/llvm/llvm-project/releases/download/llvmorg-${version}/lld-${version}.src.tar.xz";
|
|
||||||
sha256 = "sha256-BeEoSmUWbQo6ETm5mT8cYyuCkwUBMWriDIiiBBcMK6Y=";
|
|
||||||
};
|
|
||||||
buildInputs = [ pkgs.wineWowPackages.stable ];
|
|
||||||
phases = [ "unpackPhase" "patchPhase" "configurePhase" "buildPhase" "installPhase" ];
|
|
||||||
patches = [ ./lld-disable-macho.diff ];
|
|
||||||
setSourceRoot = # work around https://github.com/llvm/llvm-project/issues/53281
|
|
||||||
''
|
|
||||||
mv cmake/Modules/* lld-14.0.4.src/cmake/modules
|
|
||||||
sourceRoot=lld-14.0.4.src
|
|
||||||
'';
|
|
||||||
configurePhase =
|
|
||||||
''
|
|
||||||
export HOME=`mktemp -d`
|
|
||||||
export WINEDEBUG=-all
|
|
||||||
export WINEPATH=Z:${msys2-env}/mingw64/bin\;Z:${llvm-nac3}/bin
|
|
||||||
${silenceFontconfig}
|
|
||||||
mkdir build
|
|
||||||
cd build
|
|
||||||
wine64 cmake .. -DCMAKE_BUILD_TYPE=Release -DCMAKE_INSTALL_PREFIX=Z:$out
|
|
||||||
'';
|
|
||||||
buildPhase =
|
|
||||||
''
|
|
||||||
wine64 ninja
|
|
||||||
'';
|
|
||||||
installPhase =
|
|
||||||
''
|
|
||||||
mkdir -p $out $out/nix-support
|
|
||||||
cp bin/ld.lld.exe $out
|
|
||||||
echo file binary-dist $out/ld.lld.exe >> $out/nix-support/hydra-build-products
|
|
||||||
'';
|
|
||||||
dontFixup = true;
|
|
||||||
};
|
|
||||||
wine-msys2 = pkgs.writeShellScriptBin "wine-msys2"
|
wine-msys2 = pkgs.writeShellScriptBin "wine-msys2"
|
||||||
''
|
''
|
||||||
export WINEDEBUG=-all
|
export WINEDEBUG=-all
|
||||||
|
@ -1,34 +0,0 @@
|
|||||||
diff '--color=auto' -Naur lld-14.0.1.src.orig/CMakeLists.txt lld-14.0.1.src/CMakeLists.txt
|
|
||||||
--- lld-14.0.1.src.orig/CMakeLists.txt 2022-04-12 07:44:22.000000000 +0800
|
|
||||||
+++ lld-14.0.1.src/CMakeLists.txt 2022-04-18 18:03:22.530746411 +0800
|
|
||||||
@@ -248,7 +248,6 @@
|
|
||||||
add_subdirectory(docs)
|
|
||||||
add_subdirectory(COFF)
|
|
||||||
add_subdirectory(ELF)
|
|
||||||
-add_subdirectory(MachO)
|
|
||||||
add_subdirectory(MinGW)
|
|
||||||
add_subdirectory(wasm)
|
|
||||||
|
|
||||||
diff '--color=auto' -Naur lld-14.0.1.src.orig/tools/lld/CMakeLists.txt lld-14.0.1.src/tools/lld/CMakeLists.txt
|
|
||||||
--- lld-14.0.1.src.orig/tools/lld/CMakeLists.txt 2022-04-12 07:44:22.000000000 +0800
|
|
||||||
+++ lld-14.0.1.src/tools/lld/CMakeLists.txt 2022-04-18 18:03:34.434692221 +0800
|
|
||||||
@@ -14,7 +14,6 @@
|
|
||||||
lldCommon
|
|
||||||
lldCOFF
|
|
||||||
lldELF
|
|
||||||
- lldMachO
|
|
||||||
lldMinGW
|
|
||||||
lldWasm
|
|
||||||
)
|
|
||||||
diff '--color=auto' -Naur lld-14.0.1.src.orig/tools/lld/lld.cpp lld-14.0.1.src/tools/lld/lld.cpp
|
|
||||||
--- lld-14.0.1.src.orig/tools/lld/lld.cpp 2022-04-12 07:44:22.000000000 +0800
|
|
||||||
+++ lld-14.0.1.src/tools/lld/lld.cpp 2022-04-18 18:04:08.517537288 +0800
|
|
||||||
@@ -151,8 +151,6 @@
|
|
||||||
return elf::link;
|
|
||||||
else if (f == WinLink)
|
|
||||||
return coff::link;
|
|
||||||
- else if (f == Darwin)
|
|
||||||
- return macho::link;
|
|
||||||
else if (f == Wasm)
|
|
||||||
return lld::wasm::link;
|
|
||||||
else
|
|
Loading…
Reference in New Issue
Block a user