mirror of
https://github.com/NixOS/nixpkgs.git
synced 2024-11-24 06:31:02 +00:00
racer[d]: fix RUST_SRC_PATH
`rustc.src` is a `tar.gz` archive, but we need it unpacked.
This commit is contained in:
parent
476fc5f26e
commit
496dac571c
|
@ -24,7 +24,7 @@ rustPlatform.buildRustPackage rec {
|
|||
installPhase = ''
|
||||
mkdir -p $out/bin
|
||||
cp -p target/release/racer $out/bin/
|
||||
wrapProgram $out/bin/racer --set RUST_SRC_PATH "${rustPlatform.rust.rustc.src}/src"
|
||||
wrapProgram $out/bin/racer --set RUST_SRC_PATH "${rustPlatform.rustcSrc}"
|
||||
'';
|
||||
|
||||
meta = with stdenv.lib; {
|
||||
|
|
|
@ -18,7 +18,7 @@ buildRustPackage rec {
|
|||
|
||||
buildInputs = [ makeWrapper ];
|
||||
|
||||
RUST_SRC_PATH = ''${rustPlatform.rust.rustc.src}/src'';
|
||||
RUST_SRC_PATH = rustPlatform.rustcSrc;
|
||||
|
||||
installPhase = ''
|
||||
mkdir -p $out/bin
|
||||
|
|
|
@ -5896,6 +5896,14 @@ with pkgs;
|
|||
buildRustPackage = callPackage ../build-support/rust {
|
||||
inherit rust;
|
||||
};
|
||||
|
||||
rustcSrc = stdenv.mkDerivation {
|
||||
name = "rust-src";
|
||||
src = rust.rustc.src;
|
||||
phases = ["unpackPhase" "installPhase"];
|
||||
installPhase = "mv src $out";
|
||||
};
|
||||
|
||||
});
|
||||
|
||||
rainicorn = callPackage ../development/tools/rust/rainicorn { };
|
||||
|
|
Loading…
Reference in a new issue