From 6f75579f1fb58c6deaae73322a641e9041ac7b7c Mon Sep 17 00:00:00 2001 From: "Dennis E. Mungai" <2356871+Brainiarc7@users.noreply.github.com> Date: Wed, 7 Feb 2024 00:16:46 +0300 Subject: [PATCH 1/3] Enable the full stack of CUDA-related filters via `----enable-cuda-llvm` As at the moment, this FFmpeg build's filtering capabilities are extremely limited in NVENC-based workloads, lacking multiple CUDA-based filters needed for a fully functional GPU-bound transcode. This patch adds the ``--enable-cuda-llvm` `./configure` parameter to FFmpeg's builds, with the addition of `clang` (and its' dependencies) as build requirements for these extra filters. The following filters are now additionally available, and without invoking the installation of the proprietary NVIDIA CUDA SDK: ```sh ffmpeg -filters | grep cuda ... bilateral_cuda V->V (null) T.. bwdif_cuda V->V (null) ... chromakey_cuda V->V (null) ... colorspace_cuda V->V (null) ... hwupload_cuda V->V (null) ... overlay_cuda VV->V (null) ... scale_cuda V->V (null) ... thumbnail_cuda V->V (null) T.. yadif_cuda V->V (null) ``` Licensing, therefore, remains unaffected. --- Dockerfile | 13 +++++++++++++ 1 file changed, 13 insertions(+) diff --git a/Dockerfile b/Dockerfile index 6b42350..a94b2bf 100644 --- a/Dockerfile +++ b/Dockerfile @@ -59,6 +59,11 @@ RUN \ automake \ bzip2 \ cmake \ + clang \ + clang-tools \ + libclang1 \ + clang-format \ + clangd \ diffutils \ doxygen \ g++ \ @@ -76,6 +81,13 @@ RUN \ libtool \ libv4l-dev \ libwayland-dev \ + libllvm-ocaml-dev \ + libllvm12 \ + llvm \ + llvm-dev \ + llvm-runtime \ + lldb \ + lld \ libx11-dev \ libx11-xcb-dev \ libxcb-dri3-dev \ @@ -763,6 +775,7 @@ RUN \ --enable-nonfree \ --enable-nvdec \ --enable-nvenc \ + --enable-cuda-llvm \ --enable-opencl \ --enable-openssl \ --enable-stripping \ From 3635efa0cc3362769557ca9217feb3792b95b63c Mon Sep 17 00:00:00 2001 From: aptalca <541623+aptalca@users.noreply.github.com> Date: Thu, 8 Feb 2024 22:01:50 -0500 Subject: [PATCH 2/3] simplify deps, clean up rust --- Dockerfile | 12 +----------- Dockerfile.aarch64 | 1 + README.md | 1 + readme-vars.yml | 1 + 4 files changed, 4 insertions(+), 11 deletions(-) diff --git a/Dockerfile b/Dockerfile index a94b2bf..c243f1f 100644 --- a/Dockerfile +++ b/Dockerfile @@ -60,10 +60,6 @@ RUN \ bzip2 \ cmake \ clang \ - clang-tools \ - libclang1 \ - clang-format \ - clangd \ diffutils \ doxygen \ g++ \ @@ -81,13 +77,6 @@ RUN \ libtool \ libv4l-dev \ libwayland-dev \ - libllvm-ocaml-dev \ - libllvm12 \ - llvm \ - llvm-dev \ - llvm-runtime \ - lldb \ - lld \ libx11-dev \ libx11-xcb-dev \ libxcb-dri3-dev \ @@ -787,6 +776,7 @@ RUN \ RUN \ echo "**** arrange files ****" && \ + /usr/local/lib/rustlib/uninstall.sh && ldconfig && \ mkdir -p \ /buildout/usr/local/bin \ diff --git a/Dockerfile.aarch64 b/Dockerfile.aarch64 index 46a0841..18f8800 100644 --- a/Dockerfile.aarch64 +++ b/Dockerfile.aarch64 @@ -476,6 +476,7 @@ RUN \ RUN \ echo "**** arrange files ****" && \ + /usr/local/lib/rustlib/uninstall.sh && ldconfig && \ mkdir -p \ /buildout/usr/local/bin \ diff --git a/README.md b/README.md index b75072b..6b3a92d 100644 --- a/README.md +++ b/README.md @@ -173,6 +173,7 @@ Once registered you can define the dockerfile to use with `-f Dockerfile.aarch64 ## Versions +* **08.02.24:** - Enable cuda-llvm, clean up rustc. * **01.02.24:** - Bump Mesa to v24. * **21.01.24:** - Add alsa support. * **18.01.24:** - Let the wrapper pass the ffmpeg exit code to docker run. Bump various libs. diff --git a/readme-vars.yml b/readme-vars.yml index a28a10c..e00b060 100644 --- a/readme-vars.yml +++ b/readme-vars.yml @@ -177,6 +177,7 @@ full_custom_readme: | ## Versions + * **08.02.24:** - Enable cuda-llvm, clean up rustc. * **01.02.24:** - Bump Mesa to v24. * **21.01.24:** - Add alsa support. * **18.01.24:** - Let the wrapper pass the ffmpeg exit code to docker run. Bump various libs. From a8aca108be328bc87f4a043fb76b2303d818c270 Mon Sep 17 00:00:00 2001 From: aptalca <541623+aptalca@users.noreply.github.com> Date: Thu, 8 Feb 2024 23:02:47 -0500 Subject: [PATCH 3/3] fix typo --- Dockerfile | 2 +- Dockerfile.aarch64 | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/Dockerfile b/Dockerfile index c243f1f..02111ec 100644 --- a/Dockerfile +++ b/Dockerfile @@ -776,7 +776,7 @@ RUN \ RUN \ echo "**** arrange files ****" && \ - /usr/local/lib/rustlib/uninstall.sh && + /usr/local/lib/rustlib/uninstall.sh && \ ldconfig && \ mkdir -p \ /buildout/usr/local/bin \ diff --git a/Dockerfile.aarch64 b/Dockerfile.aarch64 index 18f8800..6cb340f 100644 --- a/Dockerfile.aarch64 +++ b/Dockerfile.aarch64 @@ -476,7 +476,7 @@ RUN \ RUN \ echo "**** arrange files ****" && \ - /usr/local/lib/rustlib/uninstall.sh && + /usr/local/lib/rustlib/uninstall.sh && \ ldconfig && \ mkdir -p \ /buildout/usr/local/bin \