From e935fa1951e1fef2798365276a056b7dcaa0b118 Mon Sep 17 00:00:00 2001 From: Antoine Viallon Date: Wed, 5 Apr 2023 00:26:36 +0200 Subject: [PATCH 1/2] ffmpeg: add tensorflow dnn backend support --- pkgs/development/libraries/ffmpeg/generic.nix | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/pkgs/development/libraries/ffmpeg/generic.nix b/pkgs/development/libraries/ffmpeg/generic.nix index 0ece46f3266..c69325db75d 100644 --- a/pkgs/development/libraries/ffmpeg/generic.nix +++ b/pkgs/development/libraries/ffmpeg/generic.nix @@ -79,6 +79,7 @@ , withSsh ? withHeadlessDeps # SFTP protocol , withSvg ? withFullDeps # SVG protocol , withSvtav1 ? withFullDeps && !stdenv.isAarch64 # AV1 encoder/decoder (focused on speed and correctness) +, withTensorflow ? withFullDeps # Tensorflow dnn backend support , withTheora ? withHeadlessDeps # Theora encoder , withV4l2 ? withFullDeps && !stdenv.isDarwin # Video 4 Linux support , withV4l2M2m ? withV4l2 @@ -211,6 +212,7 @@ , libopus , librsvg , libssh +, libtensorflow , libtheora , libv4l , libva @@ -472,6 +474,7 @@ stdenv.mkDerivation (finalAttrs: { (enableFeature withSvg "librsvg") (enableFeature withSrt "libsrt") (enableFeature withSsh "libssh") + (enableFeature withTensorflow "libtensorflow") (enableFeature withTheora "libtheora") (enableFeature withV4l2 "libv4l2") (enableFeature withV4l2M2m "v4l2-m2m") @@ -596,6 +599,7 @@ stdenv.mkDerivation (finalAttrs: { ++ optionals withSsh [ libssh ] ++ optionals withSvg [ librsvg ] ++ optionals withSvtav1 [ svt-av1 ] + ++ optionals withTensorflow [ libtensorflow ] ++ optionals withTheora [ libtheora ] ++ optionals withVaapi [ (if withSmallDeps then libva else libva-minimal) ] ++ optionals withVdpau [ libvdpau ] From 43797d4b969794d8d8a99650747903cd0f512a7b Mon Sep 17 00:00:00 2001 From: Antoine Viallon Date: Tue, 25 Apr 2023 17:37:39 +0200 Subject: [PATCH 2/2] ffmpeg: don't enable tensorflow by default for full Co-authored-by: Atemu --- pkgs/development/libraries/ffmpeg/generic.nix | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pkgs/development/libraries/ffmpeg/generic.nix b/pkgs/development/libraries/ffmpeg/generic.nix index c69325db75d..73bf29ccffd 100644 --- a/pkgs/development/libraries/ffmpeg/generic.nix +++ b/pkgs/development/libraries/ffmpeg/generic.nix @@ -79,7 +79,7 @@ , withSsh ? withHeadlessDeps # SFTP protocol , withSvg ? withFullDeps # SVG protocol , withSvtav1 ? withFullDeps && !stdenv.isAarch64 # AV1 encoder/decoder (focused on speed and correctness) -, withTensorflow ? withFullDeps # Tensorflow dnn backend support +, withTensorflow ? false # Tensorflow dnn backend support , withTheora ? withHeadlessDeps # Theora encoder , withV4l2 ? withFullDeps && !stdenv.isDarwin # Video 4 Linux support , withV4l2M2m ? withV4l2