mirror of
https://github.com/oxalica/rust-overlay.git
synced 2025-10-06 00:02:40 +02:00
27 lines
574 B
Nix
27 lines
574 B
Nix
# See docs/cross_compilation.md for details.
|
|
(import <nixpkgs> {
|
|
crossSystem = {
|
|
config = "x86_64-w64-mingw32";
|
|
};
|
|
overlays = [ (import ../..) ];
|
|
}).callPackage
|
|
(
|
|
{
|
|
mkShell,
|
|
stdenv,
|
|
rust-bin,
|
|
windows,
|
|
wine64,
|
|
}:
|
|
mkShell {
|
|
nativeBuildInputs = [ rust-bin.stable.latest.minimal ];
|
|
|
|
depsBuildBuild = [ wine64 ];
|
|
buildInputs = [ windows.pthreads ];
|
|
|
|
CARGO_TARGET_X86_64_PC_WINDOWS_GNU_LINKER = "${stdenv.cc.targetPrefix}cc";
|
|
CARGO_TARGET_X86_64_PC_WINDOWS_GNU_RUNNER = "wine64";
|
|
}
|
|
)
|
|
{ }
|