diff options
author | Alyssa Ross <hi@alyssa.is> | 2023-05-09 13:43:23 +0000 |
---|---|---|
committer | Alyssa Ross <hi@alyssa.is> | 2023-11-09 10:02:24 +0100 |
commit | 506dcaabb4e004ed5db214f7efbbc278e89f6212 (patch) | |
tree | 598008dc703c9bb99df9bfe8311a926e1a900603 /pkgs/stdenv/generic/make-derivation.nix | |
parent | e3e57b8f1885bf1dc4787728479711f46a4171cc (diff) |
stdenv: fix meson rust cross compilation
Diffstat (limited to 'pkgs/stdenv/generic/make-derivation.nix')
-rw-r--r-- | pkgs/stdenv/generic/make-derivation.nix | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/pkgs/stdenv/generic/make-derivation.nix b/pkgs/stdenv/generic/make-derivation.nix index d235ffefaab40..bd0d85fc676a3 100644 --- a/pkgs/stdenv/generic/make-derivation.nix +++ b/pkgs/stdenv/generic/make-derivation.nix @@ -402,6 +402,7 @@ else let crossFile = builtins.toFile "cross-file.conf" '' [properties] + bindgen_clang_arguments = ['-target', '${stdenv.targetPlatform.config}'] needs_exe_wrapper = ${lib.boolToString (!stdenv.buildPlatform.canExecute stdenv.hostPlatform)} [host_machine] @@ -412,6 +413,7 @@ else let [binaries] llvm-config = 'llvm-config-native' + rust = ['rustc', '--target', '${stdenv.targetPlatform.rust.rustcTargetSpec}'] ''; crossFlags = lib.optionals (stdenv.hostPlatform != stdenv.buildPlatform) [ "--cross-file=${crossFile}" ]; in crossFlags ++ mesonFlags; |