mirror of
https://github.com/NixOS/nixpkgs.git
synced 2024-11-21 22:43:01 +00:00
ffmpeg: add new external libs added in 7.1 (#348798)
This commit is contained in:
commit
7a5cc17456
104
pkgs/by-name/lc/lcevcdec/package.nix
Normal file
104
pkgs/by-name/lc/lcevcdec/package.nix
Normal file
@ -0,0 +1,104 @@
|
||||
{
|
||||
cmake,
|
||||
copyPkgconfigItems,
|
||||
fetchFromGitHub,
|
||||
fmt,
|
||||
git,
|
||||
gitUpdater,
|
||||
gtest,
|
||||
lib,
|
||||
makePkgconfigItem,
|
||||
pkg-config,
|
||||
python3,
|
||||
range-v3,
|
||||
rapidjson,
|
||||
stdenv,
|
||||
testers,
|
||||
}:
|
||||
|
||||
stdenv.mkDerivation (finalAttrs: {
|
||||
pname = "lcevcdec";
|
||||
version = "3.2.1";
|
||||
|
||||
outputs = [
|
||||
"out"
|
||||
"lib"
|
||||
"dev"
|
||||
];
|
||||
|
||||
src = fetchFromGitHub {
|
||||
owner = "v-novaltd";
|
||||
repo = "LCEVCdec";
|
||||
rev = "refs/tags/${finalAttrs.version}";
|
||||
hash = "sha256-Nf0YntB1A3AH0MTXlfUHhxYbzZqeB0EH9Fe9Xrqdsts=";
|
||||
};
|
||||
|
||||
postPatch = ''
|
||||
substituteInPlace cmake/tools/version_files.py \
|
||||
--replace-fail "args.git_version" '"${finalAttrs.version}"' \
|
||||
--replace-fail "args.git_hash" '"${finalAttrs.src.rev}"' \
|
||||
--replace-fail "args.git_date" '"1970-01-01"'
|
||||
'';
|
||||
|
||||
env = {
|
||||
includedir = "${placeholder "dev"}/include";
|
||||
libdir = "${placeholder "out"}/lib";
|
||||
};
|
||||
|
||||
pkgconfigItems = [
|
||||
(makePkgconfigItem rec {
|
||||
name = "lcevc_dec";
|
||||
inherit (finalAttrs) version;
|
||||
libs = [
|
||||
"-L${variables.libdir}"
|
||||
"-llcevc_dec_api"
|
||||
];
|
||||
libsPrivate = [
|
||||
"-lpthread"
|
||||
"-llcevc_dec_core"
|
||||
];
|
||||
cflags = [
|
||||
"-I${variables.includedir}"
|
||||
];
|
||||
variables = {
|
||||
prefix = "@dev@";
|
||||
includedir = "@includedir@";
|
||||
libdir = "@libdir@";
|
||||
};
|
||||
})
|
||||
];
|
||||
|
||||
nativeBuildInputs = [
|
||||
cmake
|
||||
python3
|
||||
git
|
||||
pkg-config
|
||||
copyPkgconfigItems
|
||||
];
|
||||
|
||||
buildInputs = [
|
||||
rapidjson
|
||||
fmt
|
||||
range-v3
|
||||
];
|
||||
|
||||
cmakeFlags = [
|
||||
(lib.cmakeFeature "VN_SDK_FFMPEG_LIBS_PACKAGE" "")
|
||||
(lib.cmakeBool "VN_SDK_UNIT_TESTS" false)
|
||||
(lib.cmakeBool "VN_SDK_SAMPLE_SOURCE" false)
|
||||
];
|
||||
|
||||
passthru = {
|
||||
updateScript = gitUpdater { };
|
||||
tests.pkg-config = testers.testMetaPkgConfig finalAttrs.finalPackage;
|
||||
};
|
||||
|
||||
meta = {
|
||||
homepage = "https://github.com/v-novaltd/LCEVCdec";
|
||||
description = "MPEG-5 LCEVC Decoder";
|
||||
license = lib.licenses.bsd3Clear;
|
||||
pkgConfigModules = [ "lcevc_dec" ];
|
||||
maintainers = with lib.maintainers; [ jopejoe1 ];
|
||||
platforms = lib.platforms.all;
|
||||
};
|
||||
})
|
48
pkgs/by-name/vv/vvenc/package.nix
Normal file
48
pkgs/by-name/vv/vvenc/package.nix
Normal file
@ -0,0 +1,48 @@
|
||||
{
|
||||
lib,
|
||||
fetchFromGitHub,
|
||||
stdenv,
|
||||
gitUpdater,
|
||||
testers,
|
||||
cmake,
|
||||
}:
|
||||
|
||||
stdenv.mkDerivation (finalAttrs: {
|
||||
pname = "vvenc";
|
||||
version = "1.12.0";
|
||||
|
||||
outputs = [
|
||||
"out"
|
||||
"lib"
|
||||
"dev"
|
||||
];
|
||||
|
||||
src = fetchFromGitHub {
|
||||
owner = "fraunhoferhhi";
|
||||
repo = "vvenc";
|
||||
rev = "v${finalAttrs.version}";
|
||||
hash = "sha256-C7ApayhubunkXBqJ/EqntaFPn6zk8rZ9fUqg7kbhvAk=";
|
||||
};
|
||||
|
||||
nativeBuildInputs = [ cmake ];
|
||||
|
||||
cmakeFlags = [
|
||||
(lib.cmakeBool "VVENC_INSTALL_FULLFEATURE_APP" true)
|
||||
(lib.cmakeBool "BUILD_SHARED_LIBS" (!stdenv.hostPlatform.isStatic))
|
||||
];
|
||||
|
||||
passthru = {
|
||||
updateScript = gitUpdater { rev-prefix = "v"; };
|
||||
tests.pkg-config = testers.testMetaPkgConfig finalAttrs.finalPackage;
|
||||
};
|
||||
|
||||
meta = {
|
||||
homepage = "https://github.com/fraunhoferhhi/vvenc";
|
||||
description = "Fraunhofer Versatile Video Encoder";
|
||||
license = lib.licenses.bsd3Clear;
|
||||
mainProgram = "vvencapp";
|
||||
pkgConfigModules = [ "libvvenc" ];
|
||||
maintainers = with lib.maintainers; [ jopejoe1 ];
|
||||
platforms = lib.platforms.all;
|
||||
};
|
||||
})
|
@ -74,6 +74,8 @@
|
||||
, withJxl ? withFullDeps && lib.versionAtLeast version "5" # JPEG XL de/encoding
|
||||
, withKvazaar ? withFullDeps # HEVC encoding
|
||||
, withLadspa ? withFullDeps # LADSPA audio filtering
|
||||
, withLc3 ? withFullDeps && lib.versionAtLeast version "7.1" # LC3 de/encoding
|
||||
, withLcevcdec ? withFullDeps && lib.versionAtLeast version "7.1" # LCEVC decoding
|
||||
, withLcms2 ? withFullDeps # ICC profile support via lcms2
|
||||
, withLzma ? withHeadlessDeps # xz-utils
|
||||
, withMetal ? false # Unfree and requires manual downloading of files
|
||||
@ -125,6 +127,7 @@
|
||||
, withVpl ? false # Hardware acceleration via intel libvpl
|
||||
, withVpx ? withHeadlessDeps && stdenv.buildPlatform == stdenv.hostPlatform # VP8 & VP9 de/encoding
|
||||
, withVulkan ? withSmallDeps && !stdenv.hostPlatform.isDarwin
|
||||
, withVvenc ? withFullDeps && lib.versionAtLeast version "7.1" # H.266/VVC encoding
|
||||
, withWebp ? withHeadlessDeps # WebP encoder
|
||||
, withX264 ? withHeadlessDeps && withGPL # H.264/AVC encoder
|
||||
, withX265 ? withHeadlessDeps && withGPL # H.265/HEVC encoder
|
||||
@ -246,6 +249,7 @@
|
||||
, kvazaar
|
||||
, ladspaH
|
||||
, lame
|
||||
, lcevcdec
|
||||
, lcms2
|
||||
, libaom
|
||||
, libaribcaption
|
||||
@ -265,6 +269,7 @@
|
||||
, libilbc
|
||||
, libjack2
|
||||
, libjxl
|
||||
, liblc3
|
||||
, libmodplug
|
||||
, libmysofa
|
||||
, libopenmpt
|
||||
@ -318,6 +323,7 @@
|
||||
, vo-amrwbenc
|
||||
, vulkan-headers
|
||||
, vulkan-loader
|
||||
, vvenc
|
||||
, x264
|
||||
, x265
|
||||
, xavs
|
||||
@ -598,6 +604,9 @@ stdenv.mkDerivation (finalAttrs: {
|
||||
] ++ [
|
||||
(enableFeature withKvazaar "libkvazaar")
|
||||
(enableFeature withLadspa "ladspa")
|
||||
] ++ optionals (versionAtLeast version "7.1") [
|
||||
(enableFeature withLc3 "liblc3")
|
||||
(enableFeature withLcevcdec "liblcevc-dec")
|
||||
] ++ optionals (versionAtLeast version "5.1") [
|
||||
(enableFeature withLcms2 "lcms2")
|
||||
] ++ [
|
||||
@ -661,6 +670,9 @@ stdenv.mkDerivation (finalAttrs: {
|
||||
(enableFeature withVorbis "libvorbis")
|
||||
(enableFeature withVpx "libvpx")
|
||||
(enableFeature withVulkan "vulkan")
|
||||
] ++ optionals (versionAtLeast version "7.1") [
|
||||
(enableFeature withVvenc "libvvenc")
|
||||
] ++ [
|
||||
(enableFeature withWebp "libwebp")
|
||||
(enableFeature withX264 "libx264")
|
||||
(enableFeature withX265 "libx265")
|
||||
@ -758,6 +770,8 @@ stdenv.mkDerivation (finalAttrs: {
|
||||
++ optionals withJxl [ libjxl ]
|
||||
++ optionals withKvazaar [ kvazaar ]
|
||||
++ optionals withLadspa [ ladspaH ]
|
||||
++ optionals withLc3 [ liblc3 ]
|
||||
++ optionals withLcevcdec [ lcevcdec ]
|
||||
++ optionals withLcms2 [ lcms2 ]
|
||||
++ optionals withLzma [ xz ]
|
||||
++ optionals withMfx [ intel-media-sdk ]
|
||||
@ -804,6 +818,7 @@ stdenv.mkDerivation (finalAttrs: {
|
||||
++ optionals withVpl [ libvpl ]
|
||||
++ optionals withVpx [ libvpx ]
|
||||
++ optionals withVulkan [ vulkan-headers vulkan-loader ]
|
||||
++ optionals withVvenc [ vvenc ]
|
||||
++ optionals withWebp [ libwebp ]
|
||||
++ optionals withX264 [ x264 ]
|
||||
++ optionals withX265 [ x265 ]
|
||||
|
Loading…
Reference in New Issue
Block a user