From 470c1addffbae717142733b6a8c07eb7ea1d239f Mon Sep 17 00:00:00 2001 From: emily Date: Sat, 3 Aug 2024 02:00:18 +0200 Subject: [PATCH] vapoursynth-bestsource: init at R6 --- .../va/vapoursynth-bestsource/package.nix | 60 +++++++++++++++++++ 1 file changed, 60 insertions(+) create mode 100644 pkgs/by-name/va/vapoursynth-bestsource/package.nix diff --git a/pkgs/by-name/va/vapoursynth-bestsource/package.nix b/pkgs/by-name/va/vapoursynth-bestsource/package.nix new file mode 100644 index 000000000000..a98f93c11759 --- /dev/null +++ b/pkgs/by-name/va/vapoursynth-bestsource/package.nix @@ -0,0 +1,60 @@ +{ + lib, + stdenv, + fetchFromGitHub, + meson, + ninja, + cmake, + pkg-config, + vapoursynth, + ffmpeg, + xxHash, +}: + +stdenv.mkDerivation (finalAttrs: { + pname = "vapoursynth-bestsource"; + version = "6"; + + outputs = [ + "out" + "dev" + ]; + + src = fetchFromGitHub { + fetchSubmodules = true; + owner = "vapoursynth"; + repo = "bestsource"; + rev = "refs/tags/R${finalAttrs.version}"; + hash = "sha256-ICkdIomlkHUdK6kMeui45fvUn4OMxSrP8svB2IN+GCg="; + }; + + nativeBuildInputs = [ + meson + ninja + cmake + pkg-config + ]; + + buildInputs = [ + vapoursynth + ffmpeg + xxHash + ]; + + postPatch = '' + substituteInPlace meson.build \ + --replace-fail "vapoursynth_dep.get_variable(pkgconfig: 'libdir')" "get_option('libdir')" + ''; + + meta = { + description = "Wrapper library around FFmpeg that ensures sample and frame accurate access to audio and video"; + homepage = "https://github.com/vapoursynth/bestsource"; + license = with lib.licenses; [ + mit + wtfpl + gpl2Plus + ]; + maintainers = with lib.maintainers; [ snaki ]; + platforms = lib.platforms.x86_64; + }; +})