depot/pkgs/by-name/pr/protoc-gen-rust/package.nix
Luke Granger-Brown 57725ef3ec Squashed 'third_party/nixpkgs/' content from commit 76612b17c0ce
git-subtree-dir: third_party/nixpkgs
git-subtree-split: 76612b17c0ce71689921ca12d9ffdc9c23ce40b2
2024-11-10 23:59:47 +00:00

30 lines
696 B
Nix

{ fetchCrate
, lib
, rustPlatform
, protobuf
}:
rustPlatform.buildRustPackage rec {
pname = "protoc-gen-rust";
version = "3.5.0";
src = fetchCrate {
inherit version;
pname = "protobuf-codegen";
hash = "sha256-yGZ4auZHGtcsN6n4/FEzabsSXproyhNTJHIwujt7ijg=";
};
cargoHash = "sha256-RO3kVYkvHw8kwLaRfANtGtz88knjJ8HtmU3i0xgIDMY=";
cargoBuildFlags = ["--bin" pname];
nativeBuildInputs = [ protobuf ];
meta = with lib; {
description = "Protobuf plugin for generating Rust code";
mainProgram = "protoc-gen-rust";
homepage = "https://github.com/stepancheg/rust-protobuf";
license = licenses.mit;
maintainers = with maintainers; [ lucperkins ];
};
}