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
64 lines
1.3 KiB
Nix
64 lines
1.3 KiB
Nix
{
|
|
lib,
|
|
rustPlatform,
|
|
fetchFromGitHub,
|
|
nasm,
|
|
meson,
|
|
ninja,
|
|
pkg-config,
|
|
|
|
nix-update-script,
|
|
}:
|
|
|
|
rustPlatform.buildRustPackage (finalAttrs: {
|
|
pname = "rav1d";
|
|
version = "1.1.0";
|
|
|
|
src = fetchFromGitHub {
|
|
owner = "memorysafety";
|
|
repo = "rav1d";
|
|
tag = "v${finalAttrs.version}";
|
|
hash = "sha256-OAfuUeScdjL7xIpf6pclNyo4ugRLIIcTjjf0AwoF+7o=";
|
|
};
|
|
|
|
cargoHash = "sha256-13j0++XHcNjkVc3VZxv2ukQvhiu+heZPgaTsA1U4MGQ=";
|
|
|
|
nativeBuildInputs = [
|
|
nasm
|
|
];
|
|
|
|
# Tests are using meson
|
|
# https://github.com/memorysafety/rav1d/tree/v1.0.0?tab=readme-ov-file#running-tests
|
|
nativeCheckInputs = [
|
|
meson
|
|
ninja
|
|
pkg-config
|
|
];
|
|
|
|
checkPhase =
|
|
let
|
|
cargoTarget = rustPlatform.cargoInstallHook.targetSubdirectory;
|
|
in
|
|
''
|
|
runHook preCheck
|
|
|
|
patchShebangs .github/workflows/test.sh
|
|
.github/workflows/test.sh -r target/${cargoTarget}/release/dav1d
|
|
|
|
runHook postCheck
|
|
'';
|
|
|
|
passthru = {
|
|
updateScript = nix-update-script { };
|
|
};
|
|
|
|
meta = {
|
|
description = "AV1 cross-platform decoder, Rust port of dav1d";
|
|
homepage = "https://github.com/memorysafety/rav1d";
|
|
changelog = "https://github.com/memorysafety/rav1d/releases/tag/v${finalAttrs.version}";
|
|
license = lib.licenses.bsd2;
|
|
maintainers = with lib.maintainers; [ liberodark ];
|
|
mainProgram = "dav1d";
|
|
};
|
|
})
|