1
0
Fork 1
mirror of https://github.com/NixOS/nixpkgs.git synced 2024-12-23 07:26:54 +00:00
nixpkgs/pkgs/development/tools/rust/racer/default.nix
Daniël de Kok f780a982cf rustracer: remove rustup dependency
racer builds fine on Linux and macOS without racer as a dependency.
racer does not actually use rustup, but 'rustc --print sysroot', which
is already available through the rustc dependency.
2018-11-10 08:38:20 +01:00

38 lines
963 B
Nix

{ stdenv, fetchFromGitHub, rustPlatform, makeWrapper, substituteAll }:
rustPlatform.buildRustPackage rec {
name = "racer-${version}";
version = "2.0.14";
src = fetchFromGitHub {
owner = "racer-rust";
repo = "racer";
rev = version;
sha256 = "0kgax74qa09axq7b175ph3psprgidwgsml83wm1qwdq16gpxiaif";
};
cargoSha256 = "1j3fviimdxn6xa75z0l9wkgdnznp8q20jjs42mql6ql782dga5lk";
buildInputs = [ makeWrapper ];
preCheck = ''
export RUST_SRC_PATH="${rustPlatform.rustcSrc}"
'';
patches = [
(substituteAll {
src = ./rust-src.patch;
inherit (rustPlatform) rustcSrc;
})
./ignore-tests.patch
];
doCheck = true;
meta = with stdenv.lib; {
description = "A utility intended to provide Rust code completion for editors and IDEs";
homepage = https://github.com/racer-rust/racer;
license = licenses.mit;
maintainers = with maintainers; [ jagajaga globin ];
platforms = platforms.all;
};
}