From 59fa7b6bb44e9eb5499aa61dec866aa386ba21f5 Mon Sep 17 00:00:00 2001 From: Thierry Delafontaine Date: Sun, 17 May 2026 09:57:27 +0200 Subject: [PATCH 1/2] av1an-unwrapped: update build configuration for v0.5.2 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit - align package name casing (av1an → Av1an) with upstream project - remove custom version regex; use standard versioning - add versionCheckHook --- pkgs/by-name/av/av1an-unwrapped/package.nix | 13 ++++--------- 1 file changed, 4 insertions(+), 9 deletions(-) diff --git a/pkgs/by-name/av/av1an-unwrapped/package.nix b/pkgs/by-name/av/av1an-unwrapped/package.nix index 977cda3facd7..95428505480b 100644 --- a/pkgs/by-name/av/av1an-unwrapped/package.nix +++ b/pkgs/by-name/av/av1an-unwrapped/package.nix @@ -11,6 +11,7 @@ rav1e, rustPlatform, vapoursynth, + versionCheckHook, }: rustPlatform.buildRustPackage (finalAttrs: { @@ -19,7 +20,7 @@ rustPlatform.buildRustPackage (finalAttrs: { src = fetchFromGitHub { owner = "rust-av"; - repo = "av1an"; + repo = "Av1an"; tag = finalAttrs.version; hash = "sha256-YF+j349777pE+evvXWTo42DQn1CE0jlfKBEXUFTfcb8="; }; @@ -50,16 +51,10 @@ rustPlatform.buildRustPackage (finalAttrs: { nativeCheckInputs = [ libaom rav1e + versionCheckHook ]; - passthru = { - updateScript = nix-update-script { - extraArgs = [ - "--version-regex" - "'^(\\d*\\.\\d*\\.\\d*)$'" - ]; - }; - }; + passthru.updateScript = nix-update-script { }; meta = { description = "Cross-platform command-line encoding framework"; From c31e6db56c9300a6d0c447f4af85cfc0addf72de Mon Sep 17 00:00:00 2001 From: Thierry Delafontaine Date: Sun, 17 May 2026 10:19:26 +0200 Subject: [PATCH 2/2] av1an-unwrapped: 0.4.4 -> 0.5.2 https://github.com/rust-av/Av1an/releases/tag/0.5 https://github.com/rust-av/Av1an/releases/tag/0.5.1 https://github.com/rust-av/Av1an/releases/tag/v0.5.2 --- pkgs/by-name/av/av1an-unwrapped/package.nix | 47 +++++++++++++-------- 1 file changed, 29 insertions(+), 18 deletions(-) diff --git a/pkgs/by-name/av/av1an-unwrapped/package.nix b/pkgs/by-name/av/av1an-unwrapped/package.nix index 95428505480b..548afa8bbcf4 100644 --- a/pkgs/by-name/av/av1an-unwrapped/package.nix +++ b/pkgs/by-name/av/av1an-unwrapped/package.nix @@ -2,7 +2,6 @@ lib, stdenv, fetchFromGitHub, - fetchpatch, ffmpeg_7, libaom, nasm, @@ -16,26 +15,16 @@ rustPlatform.buildRustPackage (finalAttrs: { pname = "av1an-unwrapped"; - version = "0.4.4"; + version = "0.5.2"; src = fetchFromGitHub { owner = "rust-av"; repo = "Av1an"; - tag = finalAttrs.version; - hash = "sha256-YF+j349777pE+evvXWTo42DQn1CE0jlfKBEXUFTfcb8="; + tag = "v${finalAttrs.version}"; + hash = "sha256-JwYnDl9ZSSE+dD+ZAxuN7ywqFN314Ib/9Flh52kL3do="; }; - cargoPatches = [ - # TODO: Remove in next version - # Avoids https://github.com/shssoichiro/ffmpeg-the-third/issues/63 - # https://github.com/master-of-zen/Av1an/pull/912 - (fetchpatch { - url = "https://github.com/rust-av/Av1an/commit/e6b29a5a624434eb0dc95b7e8aa31ccf624ccb9d.patch"; - hash = "sha256-nFE04hlTzApYafSzgl/XOUdchxEjKvxXy+SKr/d6+0Q="; - }) - ]; - - cargoHash = "sha256-PcxnWkruFH4d2FqS+y3PmyA70kSe9BKtmTdCnfKnfpU="; + cargoHash = "sha256-mxWYXujwp7tYAj9bM/ZhqbyISMjvX+AYG07otcB67pg="; nativeBuildInputs = [ nasm @@ -49,11 +38,35 @@ rustPlatform.buildRustPackage (finalAttrs: { ]; nativeCheckInputs = [ - libaom + libaom.bin rav1e versionCheckHook ]; + # The encode_tests integration suite drives the full encode pipeline + # (external encoders, ffmpeg and vapoursynth source plugins at + # runtime) and only passes in upstream's prebuilt CI image, so limit + # the check phase to the unit tests. + cargoTestFlags = [ + "--workspace" + "--lib" + "--bins" + ]; + + # libvapoursynth-script spins up an embedded Python and runs + # `import vapoursynth`; without this the VSScript API fails to + # initialize during unit tests that exercise the vapoursynth code path. + preCheck = '' + export PYTHONPATH=${vapoursynth}/${vapoursynth.python3.sitePackages}''${PYTHONPATH:+:$PYTHONPATH} + ''; + + # These unit tests load blank_1080p.mkv via core.lsmas.LWLibavSource, + # which needs the L-SMASH Works plugin. + checkFlags = [ + "--skip=chunk::tests::apply_photon_noise_args_with_noise" + "--skip=scenes::tests::validate_zones_target_quality" + ]; + passthru.updateScript = nix-update-script { }; meta = { @@ -67,7 +80,5 @@ rustPlatform.buildRustPackage (finalAttrs: { license = lib.licenses.gpl3Only; maintainers = with lib.maintainers; [ getchoo ]; mainProgram = "av1an"; - # symbol index out of range file '/private/tmp/nix-build-av1an-unwrapped-0.4.4.drv-0/rustcz0anL2/librav1e-ca440893f9248a14.rlib' for architecture x86_64 - broken = stdenv.hostPlatform.system == "x86_64-darwin"; }; })