2025-07-26 11:39:35 +02:00

38 lines
811 B
Nix

{
lib,
rustPlatform,
fetchFromGitHub,
}:
rustPlatform.buildRustPackage rec {
pname = "vhdl-ls";
version = "0.85.0";
src = fetchFromGitHub {
owner = "VHDL-LS";
repo = "rust_hdl";
rev = "v${version}";
hash = "sha256-uqJiPJ86zX9r44F8D6tabw7Cp24WQoQTen3VqnjlYu0=";
};
cargoHash = "sha256-ZC9HwMwrK3xWKr+gnf3SGMUcSRkvV3HL5h9R2lmfW9Q=";
postPatch = ''
substituteInPlace vhdl_lang/src/config.rs \
--replace /usr/lib $out/lib
'';
postInstall = ''
mkdir -p $out/lib/rust_hdl
cp -r vhdl_libraries $out/lib/rust_hdl
'';
meta = {
description = "Fast VHDL language server";
homepage = "https://github.com/VHDL-LS/rust_hdl";
license = lib.licenses.mpl20;
mainProgram = "vhdl_ls";
maintainers = with lib.maintainers; [ doronbehar ];
};
}