From 33c52f27d678854317e57e527c941758c54b1ae4 Mon Sep 17 00:00:00 2001 From: Emily Date: Fri, 12 Jul 2024 12:41:55 +0100 Subject: [PATCH 01/11] tenacity: unpin ffmpeg_5 This builds fine with the current FFmpeg for me. --- pkgs/applications/audio/tenacity/default.nix | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/pkgs/applications/audio/tenacity/default.nix b/pkgs/applications/audio/tenacity/default.nix index c5606677fd45..160a032fd648 100644 --- a/pkgs/applications/audio/tenacity/default.nix +++ b/pkgs/applications/audio/tenacity/default.nix @@ -29,7 +29,7 @@ , expat , libid3tag , libopus -, ffmpeg_5 +, ffmpeg , soundtouch , pcre , portaudio @@ -104,7 +104,7 @@ stdenv.mkDerivation rec { buildInputs = [ alsa-lib expat - ffmpeg_5 + ffmpeg file flac glib From e3d715eed9de68ccf88bdfd12e853a740f692a41 Mon Sep 17 00:00:00 2001 From: Emily Date: Fri, 12 Jul 2024 13:13:58 +0100 Subject: [PATCH 02/11] unpaper: unpin ffmpeg_5 This builds fine with the current FFmpeg for me. --- pkgs/tools/graphics/unpaper/default.nix | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/pkgs/tools/graphics/unpaper/default.nix b/pkgs/tools/graphics/unpaper/default.nix index 0b84d61274d9..dc38c55397a2 100644 --- a/pkgs/tools/graphics/unpaper/default.nix +++ b/pkgs/tools/graphics/unpaper/default.nix @@ -12,7 +12,7 @@ # runtime , buildPackages -, ffmpeg_5-headless +, ffmpeg-headless # tests , nixosTests @@ -41,7 +41,7 @@ stdenv.mkDerivation rec { ]; buildInputs = [ - ffmpeg_5-headless + ffmpeg-headless ]; passthru.tests = { From b801dc281320413584dd7b9d167e176a49914899 Mon Sep 17 00:00:00 2001 From: Emily Date: Fri, 12 Jul 2024 13:18:56 +0100 Subject: [PATCH 03/11] nixos/frigate: unpin ffmpeg_5 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit It just uses the command‐line tool, and the test passes. --- nixos/modules/services/video/frigate.nix | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/nixos/modules/services/video/frigate.nix b/nixos/modules/services/video/frigate.nix index c3ec4a3c76c3..5fa67b5ca264 100644 --- a/nixos/modules/services/video/frigate.nix +++ b/nixos/modules/services/video/frigate.nix @@ -403,7 +403,7 @@ in path = with pkgs; [ # unfree: # config.boot.kernelPackages.nvidiaPackages.latest.bin - ffmpeg_5-headless + ffmpeg-headless libva-utils procps radeontop From aef28c78342df54cf064b10dc95b2902df0420f2 Mon Sep 17 00:00:00 2001 From: Emily Date: Fri, 12 Jul 2024 13:29:09 +0100 Subject: [PATCH 04/11] nixos/akkoma: unpin ffmpeg_5 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Their Dockerfile uses Alpine’s ffmpeg package, which is already on 6. They just invoke the command‐line tool and nothing they do looks particularly version‐sensitive. --- nixos/modules/services/web-apps/akkoma.nix | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/nixos/modules/services/web-apps/akkoma.nix b/nixos/modules/services/web-apps/akkoma.nix index 8ba3c7eaa1e6..17c221778d89 100644 --- a/nixos/modules/services/web-apps/akkoma.nix +++ b/nixos/modules/services/web-apps/akkoma.nix @@ -452,9 +452,9 @@ in { extraPackages = mkOption { type = with types; listOf package; - default = with pkgs; [ exiftool ffmpeg_5-headless graphicsmagick-imagemagick-compat ]; - defaultText = literalExpression "with pkgs; [ exiftool graphicsmagick-imagemagick-compat ffmpeg_5-headless ]"; - example = literalExpression "with pkgs; [ exiftool imagemagick ffmpeg_5-full ]"; + default = with pkgs; [ exiftool ffmpeg-headless graphicsmagick-imagemagick-compat ]; + defaultText = literalExpression "with pkgs; [ exiftool ffmpeg-headless graphicsmagick-imagemagick-compat ]"; + example = literalExpression "with pkgs; [ exiftool ffmpeg-full imagemagick ]"; description = '' List of extra packages to include in the executable search path of the service unit. These are needed by various configurable components such as: From ca258d2d393eb240fd4eddf9a40093e422c33116 Mon Sep 17 00:00:00 2001 From: Emily Date: Fri, 12 Jul 2024 13:45:27 +0100 Subject: [PATCH 05/11] python3Packages.av: 11.0.0 -> 12.2.0 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Pin FFmpeg to 6.x as upstream doesn’t even support 5.x any more. Unfortunately 7.x support is not yet there; I might have to handle it myself when we drop 6. --- pkgs/development/python-modules/av/default.nix | 18 ++++-------------- 1 file changed, 4 insertions(+), 14 deletions(-) diff --git a/pkgs/development/python-modules/av/default.nix b/pkgs/development/python-modules/av/default.nix index c126a8ab1fc4..bc5989284ce4 100644 --- a/pkgs/development/python-modules/av/default.nix +++ b/pkgs/development/python-modules/av/default.nix @@ -4,8 +4,7 @@ buildPythonPackage, cython, fetchFromGitHub, - fetchpatch, - ffmpeg_5-headless, + ffmpeg_6-headless, numpy, pillow, pkg-config, @@ -16,7 +15,7 @@ buildPythonPackage rec { pname = "av"; - version = "11.0.0"; + version = "12.2.0"; pyproject = true; disabled = pythonOlder "3.7"; @@ -25,25 +24,16 @@ buildPythonPackage rec { owner = "mikeboers"; repo = "PyAV"; rev = "refs/tags/v${version}"; - hash = "sha256-pCKP+4ZmZCJcG7/Qy9H6aS4svQdgaRA9S1QVNWFYhSQ="; + hash = "sha256-yPVAtL71pL/ok3bli+r/IruCrmmhNyv98pr7z3m8sbo="; }; - patches = [ - # merged upstream PR: https://github.com/PyAV-Org/PyAV/pull/1387 - (fetchpatch { - name = "use-pkg-config-env-var-fix-cross.patch"; - url = "https://github.com/PyAV-Org/PyAV/commit/ba7a2c9f716af506838d399e6ed27ed6d64d2435.patch"; - sha256 = "sha256-oH+g8sVoVCQe6DimRN38VT2GdziriwHYRAhldNxz9/E="; - }) - ]; - nativeBuildInputs = [ cython pkg-config setuptools ]; - buildInputs = [ ffmpeg_5-headless ]; + buildInputs = [ ffmpeg_6-headless ]; preCheck = '' # ensure we import the built version From bc16039841add3a6cb02e7bcdf61c950f20830b8 Mon Sep 17 00:00:00 2001 From: Emily Date: Fri, 12 Jul 2024 13:37:01 +0100 Subject: [PATCH 06/11] python3Packages.torchaudio-bin: drop ffmpeg_{4,5} MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit These don’t seem necessary. --- pkgs/development/python-modules/torchaudio/bin.nix | 12 +++++++----- 1 file changed, 7 insertions(+), 5 deletions(-) diff --git a/pkgs/development/python-modules/torchaudio/bin.nix b/pkgs/development/python-modules/torchaudio/bin.nix index 903e1641056b..44205578a38d 100644 --- a/pkgs/development/python-modules/torchaudio/bin.nix +++ b/pkgs/development/python-modules/torchaudio/bin.nix @@ -6,8 +6,6 @@ buildPythonPackage, cudaPackages, fetchurl, - ffmpeg_4, - ffmpeg_5, ffmpeg_6, sox, pythonAtLeast, @@ -33,9 +31,7 @@ buildPythonPackage rec { buildInputs = [ - # We need to patch the lib/_torchaudio_ffmpeg[4-6] - ffmpeg_4.dev - ffmpeg_5.dev + # We need to patch lib/torio/_torio_ffmpeg6 ffmpeg_6.dev sox ] @@ -63,6 +59,12 @@ buildPythonPackage rec { addAutoPatchelfSearchPath "${torch-bin}/${python.sitePackages}/torch" ''; + preFixup = '' + # TorchAudio loads the newest FFmpeg that works, so get rid of the + # old ones. + rm $out/${python.sitePackages}/torio/lib/{lib,_}torio_ffmpeg{4,5}.* + ''; + # The wheel-binary is not stripped to avoid the error of `ImportError: libtorch_cuda_cpp.so: ELF load command address/offset not properly aligned.`. dontStrip = true; From fa8873cad09c310e4f5ff2f69a28f16f212f443b Mon Sep 17 00:00:00 2001 From: Emily Date: Fri, 12 Jul 2024 14:07:21 +0100 Subject: [PATCH 07/11] wl-screenrec: pin ffmpeg_6 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit From : > Install ffmpeg 6 or later, which is a required dependency. ffmpeg > 5 may work, but is untested (open an issue or PR if you test with > ffmpeg 5 so I can update these docs on if it works or not) I guess it worked… 7.x will need a bump to the ffmpeg-sys-next crate, but see . --- pkgs/top-level/all-packages.nix | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pkgs/top-level/all-packages.nix b/pkgs/top-level/all-packages.nix index 858b353c2c8d..5df3cdaa8d49 100644 --- a/pkgs/top-level/all-packages.nix +++ b/pkgs/top-level/all-packages.nix @@ -4666,7 +4666,7 @@ with pkgs; wl-mirror = callPackage ../tools/wayland/wl-mirror { }; wl-screenrec = callPackage ../tools/wayland/wl-screenrec { - ffmpeg = ffmpeg_5; + ffmpeg = ffmpeg_6; }; wleave = callPackage ../tools/wayland/wleave { }; From fb40c82929a35dfd55564e78ff94208eb8c30719 Mon Sep 17 00:00:00 2001 From: Emily Date: Fri, 12 Jul 2024 16:27:18 +0100 Subject: [PATCH 08/11] parsec-bin: pin ffmpeg_4 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit There is an upstream version that supports FFmpeg >= 6, but it’s not available in their distributed package yet. Downgrade the FFmpeg for now until it can be bumped later. --- pkgs/applications/misc/parsec/bin.nix | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/pkgs/applications/misc/parsec/bin.nix b/pkgs/applications/misc/parsec/bin.nix index 436822aa2b88..3bd2734597a3 100644 --- a/pkgs/applications/misc/parsec/bin.nix +++ b/pkgs/applications/misc/parsec/bin.nix @@ -16,7 +16,7 @@ , libXfixes , libpulseaudio , libva -, ffmpeg_5 +, ffmpeg_4 , libpng , libjpeg8 , curl @@ -57,7 +57,7 @@ stdenvNoCC.mkDerivation { alsa-lib libpulseaudio libva - ffmpeg_5 + ffmpeg_4 libpng libjpeg8 curl From d25171fc8e662f9df9626878948ab5897a1dea56 Mon Sep 17 00:00:00 2001 From: Emily Date: Fri, 12 Jul 2024 16:43:12 +0100 Subject: [PATCH 09/11] dim: bump nightfall for FFmpeg >= 6 support I have no idea if this works. --- pkgs/by-name/di/dim/Cargo.lock | 43 +++++++++++---------- pkgs/by-name/di/dim/bump-nightfall.patch | 48 ++++++++++++++++++++++++ pkgs/by-name/di/dim/package.nix | 14 +++++-- 3 files changed, 80 insertions(+), 25 deletions(-) create mode 100644 pkgs/by-name/di/dim/bump-nightfall.patch diff --git a/pkgs/by-name/di/dim/Cargo.lock b/pkgs/by-name/di/dim/Cargo.lock index adb78aa7a929..d0d35c8ac7cc 100644 --- a/pkgs/by-name/di/dim/Cargo.lock +++ b/pkgs/by-name/di/dim/Cargo.lock @@ -979,7 +979,7 @@ dependencies = [ "tracing-appender", "tracing-subscriber", "url", - "uuid 1.5.0", + "uuid 1.10.0", "xmlwriter", "xtra", "zip", @@ -1079,7 +1079,7 @@ dependencies = [ "tracing", "tracing-appender", "tracing-subscriber", - "uuid 1.5.0", + "uuid 1.10.0", ] [[package]] @@ -2049,14 +2049,14 @@ dependencies = [ [[package]] name = "nightfall" version = "0.3.12-rc4" -source = "git+https://github.com/Dusk-Labs/nightfall?tag=0.3.12-rc4#147ea96146b4cae6f666741020cef0622a90d46c" +source = "git+https://github.com/Dusk-Labs/nightfall?rev=878f07edd5d2c71261c5ae02fe3a6db7cda18be7#878f07edd5d2c71261c5ae02fe3a6db7cda18be7" dependencies = [ "async-trait", "cfg-if", "err-derive", "lazy_static", "mp4", - "nix 0.20.0", + "nix 0.27.1", "ntapi", "once_cell", "psutil", @@ -2067,24 +2067,12 @@ dependencies = [ "tokio", "tokio-stream", "tracing", - "uuid 0.8.2", + "uuid 1.10.0", "winapi", "xtra", "xtra_proc", ] -[[package]] -name = "nix" -version = "0.20.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fa9b4819da1bc61c0ea48b63b7bc8604064dd43013e7cc325df098d49cd7c18a" -dependencies = [ - "bitflags 1.3.2", - "cc", - "cfg-if", - "libc", -] - [[package]] name = "nix" version = "0.23.2" @@ -2098,6 +2086,17 @@ dependencies = [ "memoffset 0.6.5", ] +[[package]] +name = "nix" +version = "0.27.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "2eb04e9c688eff1c89d72b407f168cf79bb9e867a9d3323ed6c01519eb9cc053" +dependencies = [ + "bitflags 2.4.1", + "cfg-if", + "libc", +] + [[package]] name = "no-std-compat" version = "0.4.1" @@ -2140,9 +2139,9 @@ dependencies = [ [[package]] name = "ntapi" -version = "0.3.7" +version = "0.4.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c28774a7fd2fbb4f0babd8237ce554b73af68021b5f695a3cebd6c59bac0980f" +checksum = "e8a3895c6391c39d7fe7ebc444a87eb2991b2a0bc718fdabd071eec617fc68e4" dependencies = [ "winapi", ] @@ -3505,7 +3504,7 @@ dependencies = [ "tower-layer", "tower-service", "tracing", - "uuid 1.5.0", + "uuid 1.10.0", ] [[package]] @@ -3747,9 +3746,9 @@ dependencies = [ [[package]] name = "uuid" -version = "1.5.0" +version = "1.10.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "88ad59a7560b41a70d191093a945f0b87bc1deeda46fb237479708a1d6b6cdfc" +checksum = "81dfa00651efa65069b0b6b651f4aaa31ba9e3c3ce0137aaad053604ee7e0314" dependencies = [ "getrandom", ] diff --git a/pkgs/by-name/di/dim/bump-nightfall.patch b/pkgs/by-name/di/dim/bump-nightfall.patch new file mode 100644 index 000000000000..37979efd5f78 --- /dev/null +++ b/pkgs/by-name/di/dim/bump-nightfall.patch @@ -0,0 +1,48 @@ +diff --git a/dim/Cargo.toml b/dim/Cargo.toml +index b7c8106493...38518ba29d 100644 +--- a/dim/Cargo.toml ++++ b/dim/Cargo.toml +@@ -15,7 +15,7 @@ + fdlimit = "0.2.1" + + # git dependencies +-nightfall = { git = "https://github.com/Dusk-Labs/nightfall", tag = "0.3.12-rc4", default-features = false, features = [ ++nightfall = { git = "https://github.com/Dusk-Labs/nightfall", rev = "878f07edd5d2c71261c5ae02fe3a6db7cda18be7", default-features = false, features = [ + "cuda", + "ssa_transmux", + ] } +diff --git a/dim-core/Cargo.toml b/dim-core/Cargo.toml +index b311b7c7af...ffc5d85dbb 100644 +--- a/dim-core/Cargo.toml ++++ b/dim-core/Cargo.toml +@@ -11,7 +11,7 @@ + + [dependencies] + # git dependencies +-nightfall = { git = "https://github.com/Dusk-Labs/nightfall", tag = "0.3.12-rc4", default-features = false, features = [ ++nightfall = { git = "https://github.com/Dusk-Labs/nightfall", rev = "878f07edd5d2c71261c5ae02fe3a6db7cda18be7", default-features = false, features = [ + "cuda", + "ssa_transmux", + ] } +@@ -72,7 +72,7 @@ + "json", + ] } + url = "2.2.2" +-uuid = { version = "1.2.2", features = ["v4"] } ++uuid = { version = "1.6.1", features = ["v4"] } + xmlwriter = "0.1.0" + xtra = { version = "0.5.1", features = ["tokio", "with-tokio-1"] } + +diff --git a/dim-web/Cargo.toml b/dim-web/Cargo.toml +index 2da5764d50...4c7574c0b4 100644 +--- a/dim-web/Cargo.toml ++++ b/dim-web/Cargo.toml +@@ -14,7 +14,7 @@ + dim-events = { path = "../dim-events" } + dim-core = { path = "../dim-core" } + +-nightfall = { git = "https://github.com/Dusk-Labs/nightfall", tag = "0.3.12-rc4", default-features = false, features = [ ++nightfall = { git = "https://github.com/Dusk-Labs/nightfall", rev = "878f07edd5d2c71261c5ae02fe3a6db7cda18be7", default-features = false, features = [ + "cuda", + "ssa_transmux", + ] } diff --git a/pkgs/by-name/di/dim/package.nix b/pkgs/by-name/di/dim/package.nix index fba2c5e11f0c..f7fe86ab9a98 100644 --- a/pkgs/by-name/di/dim/package.nix +++ b/pkgs/by-name/di/dim/package.nix @@ -6,7 +6,7 @@ buildNpmPackage, darwin, makeWrapper, - ffmpeg_5, + ffmpeg, git, pkg-config, sqlite, @@ -48,6 +48,10 @@ rustPlatform.buildRustPackage rec { # the working dir and PATH instead. ./relative-paths.diff + # Bump the first‐party nightfall dependency to the latest Git + # revision for FFmpeg >= 6 support. + ./bump-nightfall.patch + # Upstream has some unused imports that prevent things from compiling... # Remove for next release. (fetchpatch { @@ -57,6 +61,10 @@ rustPlatform.buildRustPackage rec { }) ]; + postPatch = '' + ln -sf ${./Cargo.lock} Cargo.lock + ''; + postConfigure = '' ln -ns $frontend ui/build ''; @@ -82,7 +90,7 @@ rustPlatform.buildRustPackage rec { lockFile = ./Cargo.lock; outputHashes = { "mp4-0.8.2" = "sha256-OtVRtOTU/yoxxoRukpUghpfiEgkKoJZNflMQ3L26Cno="; - "nightfall-0.3.12-rc4" = "sha256-DtSXdIDg7XBgzEYzHdzjrHdM1ESKTQdgByeerH5TWwU="; + "nightfall-0.3.12-rc4" = "sha256-AbSuLe3ySOla3NB+mlfHRHqHuMqQbrThAaUZ747GErE="; }; }; @@ -101,7 +109,7 @@ rustPlatform.buildRustPackage rec { postInstall = '' wrapProgram $out/bin/dim \ - --prefix PATH : ${lib.makeBinPath [ ffmpeg_5 ]} + --prefix PATH : ${lib.makeBinPath [ ffmpeg ]} ''; meta = { From 58c4f3cfc89e6486b5460a1b4bb30fc359a3796f Mon Sep 17 00:00:00 2001 From: Emily Date: Fri, 12 Jul 2024 17:54:28 +0100 Subject: [PATCH 10/11] gifski: pin ffmpeg_6 Officially supported upstream. 7.x might be a bit tricky because it uses a fork of the ffmpeg-sys-next crate. --- pkgs/top-level/all-packages.nix | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pkgs/top-level/all-packages.nix b/pkgs/top-level/all-packages.nix index 5df3cdaa8d49..9c19920dad9a 100644 --- a/pkgs/top-level/all-packages.nix +++ b/pkgs/top-level/all-packages.nix @@ -8207,7 +8207,7 @@ with pkgs; gifsicle = callPackage ../tools/graphics/gifsicle { }; gifski = callPackage ../tools/graphics/gifski { - ffmpeg = ffmpeg_5; + ffmpeg = ffmpeg_6; }; github-backup = callPackage ../tools/misc/github-backup { }; From f9eee6b0a730590f936a1d72f2d391ed7b8bb151 Mon Sep 17 00:00:00 2001 From: Emily Date: Fri, 12 Jul 2024 14:04:08 +0100 Subject: [PATCH 11/11] ffmpeg_5: drop --- .../manual/release-notes/rl-2411.section.md | 3 ++ nixos/modules/config/no-x-libs.nix | 1 - .../ffmpeg/5.1.4-CVE-2023-49502.patch | 26 ----------- pkgs/development/libraries/ffmpeg/default.nix | 9 ---- pkgs/development/libraries/ffmpeg/generic.nix | 43 ------------------- pkgs/top-level/aliases.nix | 3 ++ pkgs/top-level/all-packages.nix | 3 -- 7 files changed, 6 insertions(+), 82 deletions(-) delete mode 100644 pkgs/development/libraries/ffmpeg/5.1.4-CVE-2023-49502.patch diff --git a/nixos/doc/manual/release-notes/rl-2411.section.md b/nixos/doc/manual/release-notes/rl-2411.section.md index dbce033ab17b..ecf7bfb5c63f 100644 --- a/nixos/doc/manual/release-notes/rl-2411.section.md +++ b/nixos/doc/manual/release-notes/rl-2411.section.md @@ -202,6 +202,9 @@ - The `services.mxisd` module has been removed as both [mxisd](https://github.com/kamax-matrix/mxisd) and [ma1sd](https://github.com/ma1uta/ma1sd) are not maintained any longer. Consequently the package `pkgs.ma1sd` has also been removed. +- `ffmpeg_5` has been removed. Please use the unversioned `ffmpeg`, + pin a newer version, or if necessary pin `ffmpeg_4` for compatibility. + ## Other Notable Changes {#sec-release-24.11-notable-changes} diff --git a/nixos/modules/config/no-x-libs.nix b/nixos/modules/config/no-x-libs.nix index 930e57dbde5b..2448d08a2399 100644 --- a/nixos/modules/config/no-x-libs.nix +++ b/nixos/modules/config/no-x-libs.nix @@ -33,7 +33,6 @@ with lib; fastfetch = super.fastfetch.override { vulkanSupport = false; waylandSupport = false; x11Support = false; }; ffmpeg = super.ffmpeg.override { ffmpegVariant = "headless"; }; ffmpeg_4 = super.ffmpeg_4.override { ffmpegVariant = "headless"; }; - ffmpeg_5 = super.ffmpeg_5.override { ffmpegVariant = "headless"; }; ffmpeg_6 = super.ffmpeg_6.override { ffmpegVariant = "headless"; }; ffmpeg_7 = super.ffmpeg_7.override { ffmpegVariant = "headless"; }; # dep of graphviz, libXpm is optional for Xpm support diff --git a/pkgs/development/libraries/ffmpeg/5.1.4-CVE-2023-49502.patch b/pkgs/development/libraries/ffmpeg/5.1.4-CVE-2023-49502.patch deleted file mode 100644 index ca8b8b4d15bd..000000000000 --- a/pkgs/development/libraries/ffmpeg/5.1.4-CVE-2023-49502.patch +++ /dev/null @@ -1,26 +0,0 @@ -Based on upstream 737ede405b11a37fdd61d19cf25df296a0cb0b75, with cuda and -vulkan implementations removed, bwdif adjusted to apply to 5.1.4 - -diff --git a/libavfilter/vf_bwdif.c b/libavfilter/vf_bwdif.c -index 65c617ebb3..35c864f71e 100644 ---- a/libavfilter/vf_bwdif.c -+++ b/libavfilter/vf_bwdif.c -@@ -333,13 +333,14 @@ static int config_props(AVFilterLink *link) - if(yadif->mode&1) - link->frame_rate = av_mul_q(link->src->inputs[0]->frame_rate, (AVRational){2,1}); - -- if (link->w < 3 || link->h < 4) { -- av_log(ctx, AV_LOG_ERROR, "Video of less than 3 columns or 4 lines is not supported\n"); -+ yadif->csp = av_pix_fmt_desc_get(link->format); -+ yadif->filter = filter; -+ -+ if (AV_CEIL_RSHIFT(link->w, yadif->csp->log2_chroma_w) < 3 || AV_CEIL_RSHIFT(link->h, yadif->csp->log2_chroma_h) < 4) { -+ av_log(ctx, AV_LOG_ERROR, "Video with planes less than 3 columns or 4 lines is not supported\n"); - return AVERROR(EINVAL); - } - -- yadif->csp = av_pix_fmt_desc_get(link->format); -- yadif->filter = filter; - if (yadif->csp->comp[0].depth > 8) { - s->filter_intra = filter_intra_16bit; - s->filter_line = filter_line_c_16bit; diff --git a/pkgs/development/libraries/ffmpeg/default.nix b/pkgs/development/libraries/ffmpeg/default.nix index 88b5564ecba4..a4869184bdc6 100644 --- a/pkgs/development/libraries/ffmpeg/default.nix +++ b/pkgs/development/libraries/ffmpeg/default.nix @@ -22,11 +22,6 @@ let hash = "sha256-Q8bkuF/1uJfqttJJoObnnLX3BEduv+qxsvOrVhMvRjA="; }; - v5 = { - version = "5.1.4"; - hash = "sha256-2jUL1/xGUf7aMooST2DW41KE7bC+BtgChXmj0sAJZ90="; - }; - v6 = { version = "6.1.1"; hash = "sha256-Q0c95hbCVUHQWPoh5uC8uzMylmB4BnWg+VhXEgSouzo="; @@ -43,10 +38,6 @@ rec { ffmpeg_4-headless = mkFFmpeg v4 "headless"; ffmpeg_4-full = mkFFmpeg v4 "full"; - ffmpeg_5 = mkFFmpeg v5 "small"; - ffmpeg_5-headless = mkFFmpeg v5 "headless"; - ffmpeg_5-full = mkFFmpeg v5 "full"; - ffmpeg_6 = mkFFmpeg v6 "small"; ffmpeg_6-headless = mkFFmpeg v6 "headless"; ffmpeg_6-full = mkFFmpeg v6 "full"; diff --git a/pkgs/development/libraries/ffmpeg/generic.nix b/pkgs/development/libraries/ffmpeg/generic.nix index e74bb1c2348e..9ce6a6b7a486 100644 --- a/pkgs/development/libraries/ffmpeg/generic.nix +++ b/pkgs/development/libraries/ffmpeg/generic.nix @@ -430,49 +430,6 @@ stdenv.mkDerivation (finalAttrs: { hash = "sha256-5G9lmKjMEa0+vqbA8EEiNIr6QG+PeEoIL+uZP4Hlo28="; }) ] - ++ optionals (lib.versionAtLeast version "5" && lib.versionOlder version "6") [ - (fetchpatch2 { - name = "fix_build_failure_due_to_libjxl_version_to_new"; - url = "https://git.ffmpeg.org/gitweb/ffmpeg.git/patch/75b1a555a70c178a9166629e43ec2f6250219eb2"; - hash = "sha256-+2kzfPJf5piim+DqEgDuVEEX5HLwRsxq0dWONJ4ACrU="; - }) - (fetchpatch2 { - name = "5.x-CVE-2024-31585.patch"; - url = "https://git.ffmpeg.org/gitweb/ffmpeg.git/patch/8711cea3841fc385cccb1e7255176479e865cd4d"; - hash = "sha256-WT+ly/l04yM/tRVbhkESA3sDDjwvtd/Cg2y8tQo4ApI="; - }) - (fetchpatch2 { - name = "CVE-2024-31582.patch"; - url = "https://git.ffmpeg.org/gitweb/ffmpeg.git/patch/99debe5f823f45a482e1dc08de35879aa9c74bd2"; - hash = "sha256-+CQ9FXR6Vr/AmsbXFiCUXZcxKj1s8nInEdke/Oc/kUA="; - }) - (fetchpatch2 { - name = "CVE-2024-31578.patch"; - url = "https://git.ffmpeg.org/gitweb/ffmpeg.git/patch/3bb00c0a420c3ce83c6fafee30270d69622ccad7"; - hash = "sha256-oZMZysBA+/gwaGEM1yvI+8wCadXWE7qLRL6Emap3b8Q="; - }) - ./5.1.4-CVE-2023-49502.patch - (fetchpatch2 { - name = "CVE-2023-50008.patch"; - url = "https://git.ffmpeg.org/gitweb/ffmpeg.git/patch/5f87a68cf70dafeab2fb89b42e41a4c29053b89b"; - hash = "sha256-sqUUSOPTPLwu2h8GbAw4SfEf+0oWioz52BcpW1n4v3Y="; - }) - (fetchpatch2 { - name = "CVE-2023-51793.patch"; - url = "https://git.ffmpeg.org/gitweb/ffmpeg.git/patch/8b8b4bdef311f88c0075a06a25320187aff00bf2"; - hash = "sha256-e7oGyOfUXuA8XK3vfygNtFlHpHl92O2KSLAo50sNJ5o="; - }) - (fetchpatch2 { - name = "CVE-2023-51796.patch"; - url = "https://git.ffmpeg.org/gitweb/ffmpeg.git/patch/e01a55c5283b82667dad347331816a5e20869ce9"; - hash = "sha256-m4rq+UFG3nXdgOJ3S6XcruMZ+CPw+twmy2HFv3cnvJc="; - }) - (fetchpatch2 { - name = "CVE-2023-51794.patch"; - url = "https://git.ffmpeg.org/gitweb/ffmpeg.git/patch/50f0f8c53c818f73fe2d752708e2fa9d2a2d8a07"; - hash = "sha256-5G9lmKjMEa0+vqbA8EEiNIr6QG+PeEoIL+uZP4Hlo28="; - }) - ] ++ optionals (lib.versionAtLeast version "6.1" && lib.versionOlder version "6.2") [ (fetchpatch2 { # this can be removed post 6.1 name = "fix_build_failure_due_to_PropertyKey_EncoderID"; diff --git a/pkgs/top-level/aliases.nix b/pkgs/top-level/aliases.nix index 2cea9e2a92e8..146617cab706 100644 --- a/pkgs/top-level/aliases.nix +++ b/pkgs/top-level/aliases.nix @@ -430,6 +430,9 @@ mapAliases ({ fcitx5-catppuccin = catppuccin-fcitx5; # Added 2024-06-19 inherit (luaPackages) fennel; # Added 2022-09-24 fetchFromGithub = throw "You meant fetchFromGitHub, with a capital H"; # preserve + ffmpeg_5 = throw "ffmpeg_5 has been removed, please use a newer version or ffmpeg_4 for compatibility"; # Added 2024-07-12 + ffmpeg_5-headless = throw "ffmpeg_5-headless has been removed, please use a newer version or ffmpeg_4-headless for compatibility"; # Added 2024-07-12 + ffmpeg_5-full = throw "ffmpeg_5-full has been removed, please use a newer version or ffmpeg_4-full for compatibility"; # Added 2024-07-12 FIL-plugins = fil-plugins; # Added 2024-06-12 findimagedupes = throw "findimagedupes has been removed because the perl bindings are no longer compatible"; # Added 2023-07-10 finger_bsd = bsd-finger; diff --git a/pkgs/top-level/all-packages.nix b/pkgs/top-level/all-packages.nix index 9c19920dad9a..1049020231e7 100644 --- a/pkgs/top-level/all-packages.nix +++ b/pkgs/top-level/all-packages.nix @@ -20381,9 +20381,6 @@ with pkgs; ffmpeg_4 ffmpeg_4-headless ffmpeg_4-full - ffmpeg_5 - ffmpeg_5-headless - ffmpeg_5-full ffmpeg_6 ffmpeg_6-headless ffmpeg_6-full