diff --git a/pkgs/by-name/lu/lurk/package.nix b/pkgs/by-name/lu/lurk/package.nix index f3a737cefadd..ad43e981d6b0 100644 --- a/pkgs/by-name/lu/lurk/package.nix +++ b/pkgs/by-name/lu/lurk/package.nix @@ -2,6 +2,9 @@ lib, rustPlatform, fetchFromGitHub, + fetchpatch, + versionCheckHook, + nix-update-script, }: rustPlatform.buildRustPackage (finalAttrs: { @@ -15,6 +18,14 @@ rustPlatform.buildRustPackage (finalAttrs: { hash = "sha256-Sng+mMMKDuI1aSgusJDRFMT5iKNUlp9arp9ruRn0bb0="; }; + patches = [ + (fetchpatch { + name = "fix-aarch64-build.patch"; + url = "https://github.com/JakWai01/lurk/commit/132e6557ddeafbdb1bb1d4d1411099f0d7df7a51.patch?full_index=1"; + hash = "sha256-B5rNLipnFFWxIhTm+eCacJkw38D7stQ27WIHzgj7Vy0="; + }) + ]; + cargoHash = "sha256-Cmlhhda35FmNg/OvfMRPHBLPRXF5bs0ebBYT7KfierA="; postPatch = '' @@ -22,6 +33,14 @@ rustPlatform.buildRustPackage (finalAttrs: { --replace-fail '/usr/bin/ls' 'ls' ''; + doInstallCheck = true; + nativeInstallCheckInputs = [ + versionCheckHook + ]; + versionCheckProgramArg = "--version"; + + passthru.updateScript = nix-update-script { }; + meta = { changelog = "https://github.com/jakwai01/lurk/releases/tag/v${finalAttrs.version}"; description = "Simple and pretty alternative to strace";