Loading pkgs/development/tools/rust/bindgen/default.nix +7 −6 Original line number Diff line number Diff line Loading @@ -10,11 +10,8 @@ let self = runCommand "rust-bindgen-${rust-bindgen-unwrapped.version}" { #for substituteAll inherit bash; pname = "rust-bindgen"; inherit (rust-bindgen-unwrapped) version; unwrapped = rust-bindgen-unwrapped; meta = rust-bindgen-unwrapped.meta // { longDescription = rust-bindgen-unwrapped.meta.longDescription + '' This version of bindgen is wrapped with the required compiler flags Loading Loading @@ -46,9 +43,13 @@ let # if you modify the logic to find the right clang flags, also modify rustPlatform.bindgenHook '' mkdir -p $out/bin export cincludes="$(< ${clang}/nix-support/cc-cflags) $(< ${clang}/nix-support/libc-cflags)" export cxxincludes="$(< ${clang}/nix-support/libcxx-cxxflags)" substituteAll ${./wrapper.sh} $out/bin/bindgen cincludes="$(< ${clang}/nix-support/cc-cflags) $(< ${clang}/nix-support/libc-cflags)" cxxincludes="$(< ${clang}/nix-support/libcxx-cxxflags)" substitute ${./wrapper.sh} $out/bin/bindgen \ --replace-fail "@bash@" "${bash}" \ --replace-fail "@cxxincludes@" "$cxxincludes" \ --replace-fail "@cincludes@" "$cincludes" \ --replace-fail "@unwrapped@" "${rust-bindgen-unwrapped}" chmod +x $out/bin/bindgen ''; in Loading Loading
pkgs/development/tools/rust/bindgen/default.nix +7 −6 Original line number Diff line number Diff line Loading @@ -10,11 +10,8 @@ let self = runCommand "rust-bindgen-${rust-bindgen-unwrapped.version}" { #for substituteAll inherit bash; pname = "rust-bindgen"; inherit (rust-bindgen-unwrapped) version; unwrapped = rust-bindgen-unwrapped; meta = rust-bindgen-unwrapped.meta // { longDescription = rust-bindgen-unwrapped.meta.longDescription + '' This version of bindgen is wrapped with the required compiler flags Loading Loading @@ -46,9 +43,13 @@ let # if you modify the logic to find the right clang flags, also modify rustPlatform.bindgenHook '' mkdir -p $out/bin export cincludes="$(< ${clang}/nix-support/cc-cflags) $(< ${clang}/nix-support/libc-cflags)" export cxxincludes="$(< ${clang}/nix-support/libcxx-cxxflags)" substituteAll ${./wrapper.sh} $out/bin/bindgen cincludes="$(< ${clang}/nix-support/cc-cflags) $(< ${clang}/nix-support/libc-cflags)" cxxincludes="$(< ${clang}/nix-support/libcxx-cxxflags)" substitute ${./wrapper.sh} $out/bin/bindgen \ --replace-fail "@bash@" "${bash}" \ --replace-fail "@cxxincludes@" "$cxxincludes" \ --replace-fail "@cincludes@" "$cincludes" \ --replace-fail "@unwrapped@" "${rust-bindgen-unwrapped}" chmod +x $out/bin/bindgen ''; in Loading