Impossible to rebuild media-video/handbrake-1.9.2 -- cmake version 4.0.3 CMake Error at CMakeLists.txt:10 (cmake_policy): Policy CMP0025 may not be set to OLD behavior because this version of CMake no longer supports it. The policy was introduced in CMake version 3.0.0, and use of NEW behavior is now required. Please either update your CMakeLists.txt files to conform to the new behavior or use an older version of CMake that still supports the old behavior. Run cmake --help-policy CMP0025 for more information. CMake Error at CMakeLists.txt:16 (cmake_policy): Policy CMP0054 may not be set to OLD behavior because this version of CMake no longer supports it. The policy was introduced in CMake version 3.1.0, and use of NEW behavior is now required. Please either update your CMakeLists.txt files to conform to the new behavior or use an older version of CMake that still supports the old behavior. Run cmake --help-policy CMP0054 for more information. CMake Warning (dev) at CMakeLists.txt:19 (project): cmake_minimum_required() should be called prior to this top-level project() call. Please see the cmake-commands(7) manual for usage documentation of both commands. This warning is for project developers. Use -Wno-dev to suppress it. -- The C compiler identification is GNU 15.1.0 -- The CXX compiler identification is GNU 15.1.0 -- Detecting C compiler ABI info -- Detecting C compiler ABI info - done -- Check for working C compiler: /usr/lib/ccache/bin/x86_64-pc-linux-gnu-gcc - skipped -- Detecting C compile features -- Detecting C compile features - done -- Detecting CXX compiler ABI info -- Detecting CXX compiler ABI info - done -- Check for working CXX compiler: /usr/lib/ccache/bin/x86_64-pc-linux-gnu-g++ - skipped -- Detecting CXX compile features -- Detecting CXX compile features - done CMake Error at CMakeLists.txt:20 (cmake_minimum_required): Compatibility with CMake < 3.5 has been removed from CMake. Update the VERSION argument <min> value. Or, use the <min>...<max> syntax to tell CMake that the project requires at least <min> but has been updated to work with policies introduced by <max> or earlier. Or, add -DCMAKE_POLICY_VERSION_MINIMUM=3.5 to try configuring anyway. -- Configuring incomplete, errors occurred! make: *** [../contrib/x265_8bit/module.rules:2: contrib/x265/.stamp.x265_8.configure] Error 1 make: *** Waiting for unfinished jobs.... touch contrib/ffmpeg/.stamp.ffmpeg.extract make: Leaving directory '/var/tmp/portage/media-video/handbrake-1.9.2/work/HandBrake-1.9.2/build' Reproducible: Always Steps to Reproduce: 1. try to rebuild media-video/handbrake-1.9.2 Actual Results: It does not build. Expected Results: It builds. $ emerge -pqv '=media-video/handbrake-1.9.2::gentoo' [ebuild R ] media-video/handbrake-1.9.2 USE="amf fdk gui x265 -libdovi -numa -nvenc -qsv"
Created attachment 934408 [details] emerge --info '=media-video/handbrake-1.9.2::gentoo'
Created attachment 934409 [details] /var/tmp/portage/media-video/handbrake-1.9.2/temp/build.log
Created attachment 934410 [details] /var/tmp/portage/media-video/handbrake-1.9.2/temp/environment
This is fixed in the next (unreleased) version by virtue of updating the vendored x265. Otherwise we will have patch it ourselves through whatever mechanism upstream uses themselves. https://bitbucket.org/multicoreware/x265_git/commits/51ae8e922bcc4586ad4710812072289af91492a8 https://github.com/HandBrake/HandBrake/commit/2ac30707771311e131296f5854b5381801bd07d1
They clearly says that 1.9.x is not supported with >=cmake-4. https://github.com/HandBrake/HandBrake/issues/6855#issuecomment-2847873350 So I suggest to limit cmake version as build depend.
(In reply to Reva Denis from comment #5) > So I suggest to limit cmake version as build depend. That's not acceptable.
The bug has been referenced in the following commit(s): https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=c277d74e35cac56dd63b1e9d0fc754823f39a12f commit c277d74e35cac56dd63b1e9d0fc754823f39a12f Author: Alfred Wingate <parona@protonmail.com> AuthorDate: 2025-06-15 21:28:45 +0000 Commit: Sam James <sam@gentoo.org> CommitDate: 2025-06-15 22:28:22 +0000 media-video/handbrake: handle cmake4 in x265 Bug: https://bugs.gentoo.org/958194 Signed-off-by: Alfred Wingate <parona@protonmail.com> Part-of: https://github.com/gentoo/gentoo/pull/42616 Closes: https://github.com/gentoo/gentoo/pull/42616 Signed-off-by: Sam James <sam@gentoo.org> .../files/handbrake-1.9.2-x265-cmake4.patch | 101 +++++++++++++++++++++ media-video/handbrake/handbrake-1.9.2-r1.ebuild | 5 + 2 files changed, 106 insertions(+)
Thank you maintainers for your effort.