Files
nixpkgs/pkgs/by-name/sl/slint-lsp/package.nix
Dark Steveneq 646b892680
Some checks failed
Periodic Merges (6h) / master → staging-nixos (push) Failing after 12m50s
Periodic Merges (6h) / master → staging-next (push) Failing after 12m54s
Periodic Merges (24h) / merge-base(master,staging) → haskell-updates (push) Failing after 11m54s
Periodic Merges (6h) / staging-next → staging (push) Failing after 12m13s
Periodic Merges (24h) / staging-next-25.05 → staging-25.05 (push) Failing after 13m24s
Periodic Merges (24h) / release-25.05 → staging-next-25.05 (push) Failing after 14m28s
push sheeet
2025-10-09 14:15:47 +02:00

71 lines
1.6 KiB
Nix

{
lib,
stdenv,
rustPlatform,
fetchCrate,
pkg-config,
cmake,
fontconfig,
libGL,
xorg,
libxkbcommon,
wayland,
versionCheckHook,
nix-update-script,
}:
rustPlatform.buildRustPackage (finalAttrs: {
pname = "slint-lsp";
version = "1.13.1";
src = fetchCrate {
inherit (finalAttrs) pname version;
hash = "sha256-XEs7zJWocRZgVPPDM/IxOOwE7ofh+b7A/TJrQw/mMOo=";
};
cargoHash = "sha256-DAoqfnis95oEPBgYeOdR3zUVdoKbay780iJ6zVkxdDU=";
rpathLibs = [
fontconfig
libGL
xorg.libxcb
xorg.libX11
xorg.libXcursor
xorg.libXi
]
++ lib.optionals stdenv.hostPlatform.isLinux [
libxkbcommon
wayland
];
nativeBuildInputs = [
cmake
pkg-config
fontconfig
];
buildInputs = finalAttrs.rpathLibs ++ [ xorg.libxcb.dev ];
# Tests requires `i_slint_backend_testing` which is only a dev dependency
doCheck = false;
postInstall = lib.optionalString stdenv.hostPlatform.isLinux ''
patchelf --set-rpath ${lib.makeLibraryPath finalAttrs.rpathLibs} $out/bin/slint-lsp
'';
dontPatchELF = true;
doInstallCheck = true;
nativeInstallCheckInputs = [ versionCheckHook ];
passthru.updateScript = nix-update-script { };
meta = {
description = "Language Server Protocol (LSP) for Slint UI language";
mainProgram = "slint-lsp";
homepage = "https://slint-ui.com/";
downloadPage = "https://github.com/slint-ui/slint/";
changelog = "https://github.com/slint-ui/slint/blob/v${finalAttrs.version}/CHANGELOG.md";
license = with lib.licenses; [ gpl3Plus ];
maintainers = with lib.maintainers; [ xgroleau ];
};
})