diff options
author | Michael Eden <themichaeleden@gmail.com> | 2019-03-12 09:07:36 -0400 |
---|---|---|
committer | John Ericson <git@JohnEricson.me> | 2019-03-29 11:11:00 -0400 |
commit | f93470d7a318d91740120e45f8cc6455bc7c56ef (patch) | |
tree | c3cb37040a8153bf626db04c878e75ff52b985eb /pkgs/build-support/rust | |
parent | bdd3c3fdcb11416d2e2ef459c2e28caa2235f0f3 (diff) | |
download | nixpkgs-f93470d7a318d91740120e45f8cc6455bc7c56ef.tar nixpkgs-f93470d7a318d91740120e45f8cc6455bc7c56ef.tar.gz nixpkgs-f93470d7a318d91740120e45f8cc6455bc7c56ef.tar.bz2 nixpkgs-f93470d7a318d91740120e45f8cc6455bc7c56ef.tar.lz nixpkgs-f93470d7a318d91740120e45f8cc6455bc7c56ef.tar.xz nixpkgs-f93470d7a318d91740120e45f8cc6455bc7c56ef.tar.zst nixpkgs-f93470d7a318d91740120e45f8cc6455bc7c56ef.zip |
rust: set PKG_CONFIG_ALLOW_CROSS conditionally in buildRustPackage
Diffstat (limited to 'pkgs/build-support/rust')
-rw-r--r-- | pkgs/build-support/rust/default.nix | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/pkgs/build-support/rust/default.nix b/pkgs/build-support/rust/default.nix index 028390640d1..2579c97b99e 100644 --- a/pkgs/build-support/rust/default.nix +++ b/pkgs/build-support/rust/default.nix @@ -56,6 +56,9 @@ in stdenv.mkDerivation (args // { patches = cargoPatches ++ patches; + PKG_CONFIG_ALLOW_CROSS = + if stdenv.buildPlatform != stdenv.hostPlatform then 1 else 0; + postUnpack = '' eval "$cargoDepsHook" |