From ecba63d3e6e0b055f0203832fbeb006e3a9a327a Mon Sep 17 00:00:00 2001 From: Alyssa Ross Date: Sun, 25 Aug 2024 14:09:29 +0000 Subject: [PATCH] rustc: fix building with MinGW target Building std requires dlltool for the target platform. --- pkgs/development/compilers/rust/rustc.nix | 2 ++ 1 file changed, 2 insertions(+) diff --git a/pkgs/development/compilers/rust/rustc.nix b/pkgs/development/compilers/rust/rustc.nix index 8cbe04532fb9..509f255fda78 100644 --- a/pkgs/development/compilers/rust/rustc.nix +++ b/pkgs/development/compilers/rust/rustc.nix @@ -3,6 +3,7 @@ , runCommandLocal, fetchurl, file, python3 , darwin, cargo, cmake, rustc, rustfmt , pkg-config, openssl, xz, zlib +, bintools , libiconv , which, libffi , withBundledLLVM ? false @@ -247,6 +248,7 @@ in stdenv.mkDerivation (finalAttrs: { dontUseCmakeConfigure = true; depsBuildBuild = [ pkgsBuildHost.stdenv.cc pkg-config ]; + depsBuildTarget = lib.optionals stdenv.targetPlatform.isMinGW [ bintools ]; nativeBuildInputs = [ file python3 rustc cmake