build-rust-crate: add global libiconv darwin buildInputs

This commit is contained in:
happysalada 2021-09-03 12:38:43 +09:00 committed by Raphael Megzari
parent 0585c981f1
commit c9f0c6f115
2 changed files with 3 additions and 3 deletions

View File

@ -13,6 +13,7 @@
, rust
, cargo
, jq
, libiconv
}:
let
@ -258,7 +259,7 @@ crate_: lib.makeOverridable
version = crate.version;
depsBuildBuild = [ pkgsBuildBuild.stdenv.cc ];
nativeBuildInputs = [ rust stdenv.cc cargo jq ] ++ (crate.nativeBuildInputs or [ ]) ++ nativeBuildInputs_;
buildInputs = (crate.buildInputs or [ ]) ++ buildInputs_;
buildInputs = lib.optionals stdenv.isDarwin [ libiconv ] ++ (crate.buildInputs or [ ]) ++ buildInputs_;
dependencies = map lib.getLib dependencies_;
buildDependencies = map lib.getLib buildDependencies_;

View File

@ -3,7 +3,6 @@
, pkg-config
, curl
, darwin
, libiconv
, libgit2
, libssh2
, openssl
@ -40,7 +39,7 @@ in
cargo = attrs: {
buildInputs = [ openssl zlib curl ]
++ lib.optionals stdenv.isDarwin [ CoreFoundation Security libiconv ];
++ lib.optionals stdenv.isDarwin [ CoreFoundation Security ];
};
libz-sys = attrs: {