diff options
author | Sandro <sandro.jaeckel@gmail.com> | 2021-01-22 02:16:08 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2021-01-22 02:16:08 +0100 |
commit | d78f0383c2c2d7ccb4fd9e9771c57f33de04aee5 (patch) | |
tree | aa2c521a131a1794fd735333c7d8cc89ead6bd01 | |
parent | 74a5242641a03edf2cc345f3296a3f9fad4adf34 (diff) | |
parent | 23b0a88572577777d6fa4f9e5810da3c6a6e9c50 (diff) |
Merge pull request #110383 from ck3d/fix-rust-bindgen
rust-bindgen: Resolve "/usr/bin/env bash" to fix usage in Nix build
-rw-r--r-- | pkgs/development/tools/rust/bindgen/default.nix | 10 | ||||
-rwxr-xr-x | pkgs/development/tools/rust/bindgen/wrapper.sh | 2 |
2 files changed, 8 insertions, 4 deletions
diff --git a/pkgs/development/tools/rust/bindgen/default.nix b/pkgs/development/tools/rust/bindgen/default.nix index 0330edb4804b..eef8a5e41fd2 100644 --- a/pkgs/development/tools/rust/bindgen/default.nix +++ b/pkgs/development/tools/rust/bindgen/default.nix @@ -1,5 +1,7 @@ -{ lib, stdenv, fetchFromGitHub, rustPlatform, clang, llvmPackages, rustfmt, writeScriptBin, - runtimeShell }: +{ lib, stdenv, fetchFromGitHub, rustPlatform, clang, llvmPackages, rustfmt, writeScriptBin +, runtimeShell +, bash +}: rustPlatform.buildRustPackage rec { pname = "rust-bindgen"; @@ -16,7 +18,9 @@ rustPlatform.buildRustPackage rec { cargoSha256 = "1dv1ywdy701bnc2jv5jq0hnpal1snlizaj9w6k1wxyrp9szjd48w"; - libclang = llvmPackages.libclang.lib; #for substituteAll + #for substituteAll + libclang = llvmPackages.libclang.lib; + inherit bash; buildInputs = [ libclang ]; diff --git a/pkgs/development/tools/rust/bindgen/wrapper.sh b/pkgs/development/tools/rust/bindgen/wrapper.sh index 95cd0901cec8..0b3e3cd4c1e0 100755 --- a/pkgs/development/tools/rust/bindgen/wrapper.sh +++ b/pkgs/development/tools/rust/bindgen/wrapper.sh @@ -1,4 +1,4 @@ -#!/usr/bin/env bash +#!@bash@/bin/bash sep='--' # whether to add -- before new options cxx=0 # whether cxx was explicitly requested lastWasx=0 # whether the last argument passed was -x |