Merge pull request #159461 from dali99/libaom-tunes
libaom: Add support for butteraugli and vmaf tunes
This commit is contained in:
commit
ce660322e3
|
@ -1,4 +1,7 @@
|
||||||
{ lib, stdenv, fetchzip, yasm, perl, cmake, pkg-config, python3 }:
|
{ lib, stdenv, fetchzip, yasm, perl, cmake, pkg-config, python3
|
||||||
|
, enableButteraugli ? false, libjxl, libhwy # Broken
|
||||||
|
, enableVmaf ? true, libvmaf
|
||||||
|
}:
|
||||||
|
|
||||||
stdenv.mkDerivation rec {
|
stdenv.mkDerivation rec {
|
||||||
pname = "libaom";
|
pname = "libaom";
|
||||||
|
@ -16,6 +19,11 @@ stdenv.mkDerivation rec {
|
||||||
yasm perl cmake pkg-config python3
|
yasm perl cmake pkg-config python3
|
||||||
];
|
];
|
||||||
|
|
||||||
|
buildInputs = lib.optionals enableButteraugli [
|
||||||
|
libjxl
|
||||||
|
libhwy
|
||||||
|
] ++ lib.optional enableVmaf libvmaf;
|
||||||
|
|
||||||
preConfigure = ''
|
preConfigure = ''
|
||||||
# build uses `git describe` to set the build version
|
# build uses `git describe` to set the build version
|
||||||
cat > $NIX_BUILD_TOP/git << "EOF"
|
cat > $NIX_BUILD_TOP/git << "EOF"
|
||||||
|
@ -32,6 +40,10 @@ stdenv.mkDerivation rec {
|
||||||
cmakeFlags = [
|
cmakeFlags = [
|
||||||
"-DBUILD_SHARED_LIBS=ON"
|
"-DBUILD_SHARED_LIBS=ON"
|
||||||
"-DENABLE_TESTS=OFF"
|
"-DENABLE_TESTS=OFF"
|
||||||
|
] ++ lib.optionals enableButteraugli [
|
||||||
|
"-DCONFIG_TUNE_BUTTERAUGLI=1"
|
||||||
|
] ++ lib.optionals enableVmaf [
|
||||||
|
"-DCONFIG_TUNE_VMAF=1"
|
||||||
] ++ lib.optionals (stdenv.isDarwin && stdenv.isAarch64) [
|
] ++ lib.optionals (stdenv.isDarwin && stdenv.isAarch64) [
|
||||||
# CPU detection isn't supported on Darwin and breaks the aarch64-darwin build:
|
# CPU detection isn't supported on Darwin and breaks the aarch64-darwin build:
|
||||||
"-DCONFIG_RUNTIME_CPU_DETECT=0"
|
"-DCONFIG_RUNTIME_CPU_DETECT=0"
|
||||||
|
@ -58,7 +70,7 @@ stdenv.mkDerivation rec {
|
||||||
'';
|
'';
|
||||||
homepage = "https://aomedia.org/av1-features/get-started/";
|
homepage = "https://aomedia.org/av1-features/get-started/";
|
||||||
changelog = "https://aomedia.googlesource.com/aom/+/refs/tags/v${version}/CHANGELOG";
|
changelog = "https://aomedia.googlesource.com/aom/+/refs/tags/v${version}/CHANGELOG";
|
||||||
maintainers = with maintainers; [ primeos kiloreux ];
|
maintainers = with maintainers; [ primeos kiloreux dandellion ];
|
||||||
platforms = platforms.all;
|
platforms = platforms.all;
|
||||||
license = licenses.bsd2;
|
license = licenses.bsd2;
|
||||||
};
|
};
|
||||||
|
|
|
@ -1,10 +1,7 @@
|
||||||
{ stdenv, lib, fetchFromGitHub
|
{ stdenv, lib, fetchFromGitHub
|
||||||
, fetchpatch
|
, fetchpatch
|
||||||
, asciidoc
|
|
||||||
, brotli
|
, brotli
|
||||||
, cmake
|
, cmake
|
||||||
, graphviz
|
|
||||||
, doxygen
|
|
||||||
, giflib
|
, giflib
|
||||||
, gperftools
|
, gperftools
|
||||||
, gtest
|
, gtest
|
||||||
|
@ -14,8 +11,12 @@
|
||||||
, libwebp
|
, libwebp
|
||||||
, openexr
|
, openexr
|
||||||
, pkg-config
|
, pkg-config
|
||||||
, python3
|
|
||||||
, zlib
|
, zlib
|
||||||
|
, buildDocs ? true
|
||||||
|
, asciidoc
|
||||||
|
, graphviz
|
||||||
|
, doxygen
|
||||||
|
, python3
|
||||||
}:
|
}:
|
||||||
|
|
||||||
stdenv.mkDerivation rec {
|
stdenv.mkDerivation rec {
|
||||||
|
@ -50,13 +51,14 @@ stdenv.mkDerivation rec {
|
||||||
];
|
];
|
||||||
|
|
||||||
nativeBuildInputs = [
|
nativeBuildInputs = [
|
||||||
asciidoc # for docs
|
|
||||||
cmake
|
cmake
|
||||||
graphviz # for docs via doxygen component `dot`
|
|
||||||
doxygen # for docs
|
|
||||||
gtest
|
gtest
|
||||||
pkg-config
|
pkg-config
|
||||||
python3 # for docs
|
] ++ lib.optionals buildDocs [
|
||||||
|
asciidoc
|
||||||
|
graphviz
|
||||||
|
doxygen
|
||||||
|
python3
|
||||||
];
|
];
|
||||||
|
|
||||||
# Functionality not currently provided by this package
|
# Functionality not currently provided by this package
|
||||||
|
|
|
@ -18187,7 +18187,10 @@ with pkgs;
|
||||||
|
|
||||||
libantlr3c = callPackage ../development/libraries/libantlr3c {};
|
libantlr3c = callPackage ../development/libraries/libantlr3c {};
|
||||||
|
|
||||||
libaom = callPackage ../development/libraries/libaom { };
|
libaom = callPackage ../development/libraries/libaom {
|
||||||
|
# Remove circular dependency for libavif
|
||||||
|
libjxl = libjxl.override { buildDocs = false; };
|
||||||
|
};
|
||||||
|
|
||||||
libappindicator-gtk2 = libappindicator.override { gtkVersion = "2"; };
|
libappindicator-gtk2 = libappindicator.override { gtkVersion = "2"; };
|
||||||
libappindicator-gtk3 = libappindicator.override { gtkVersion = "3"; };
|
libappindicator-gtk3 = libappindicator.override { gtkVersion = "3"; };
|
||||||
|
|
Loading…
Reference in a new issue