From 50f3242f3cb774eb514c59560681c93cf10f1a6f Mon Sep 17 00:00:00 2001 From: Funda Wang Date: Sat, 22 Mar 2025 22:12:27 +0800 Subject: [PATCH] fix build with cmake 4.0 --- libzen-0.4.41-port-to-newer-cmake.patch | 8 ++++++++ libzen.spec | 11 +++++++++-- 2 files changed, 17 insertions(+), 2 deletions(-) create mode 100644 libzen-0.4.41-port-to-newer-cmake.patch diff --git a/libzen-0.4.41-port-to-newer-cmake.patch b/libzen-0.4.41-port-to-newer-cmake.patch new file mode 100644 index 0000000..cbc37b2 --- /dev/null +++ b/libzen-0.4.41-port-to-newer-cmake.patch @@ -0,0 +1,8 @@ +--- ZenLib/Project/CMake/CMakeLists.txt.orig 2025-03-22 22:05:10.888924100 +0800 ++++ ZenLib/Project/CMake/CMakeLists.txt 2025-03-22 22:06:17.002136100 +0800 +@@ -1,4 +1,4 @@ +-cmake_minimum_required(VERSION 3.1.0) ++cmake_minimum_required(VERSION 3.1.0...${CMAKE_VERSION}) + + project(ZenLib) + diff --git a/libzen.spec b/libzen.spec index 068bdc9..6e628cb 100644 --- a/libzen.spec +++ b/libzen.spec @@ -1,18 +1,20 @@ Name: libzen Version: 0.4.41 -Release: 3 +Release: 4 Summary: Shared library for libmediainfo and medianfo* Summary(ru): Разделяемая библиотека для libmediainfo и medianfo* License: zlib URL: https://github.com/MediaArea/ZenLib Source0: https://mediaarea.net/download/source/%{name}/%{version}/%{name}_%{version}.tar.gz +Patch0: libzen-0.4.41-port-to-newer-cmake.patch BuildRequires: gcc BuildRequires: gcc-c++ BuildRequires: doxygen BuildRequires: cmake BuildRequires: pkgconfig(zlib) +BuildRequires: dos2unix %description Files shared library for libmediainfo and medianfo-*. @@ -44,7 +46,9 @@ Include files and mandatory libraries for development. Файлы для разработки %{name}. %prep -%autosetup -n ZenLib +%setup -qn ZenLib +dos2unix Project/CMake/CMakeLists.txt +%autopatch -p1 #Correct documentation encoding and permissions sed -i 's/.$//' *.txt @@ -85,6 +89,9 @@ cp Source/Doc/*.html ./ %changelog +* Sat Mar 22 2025 Funda Wang - 0.4.41-4 +- fix build with cmake 4.0 + * Thu Dec 12 2024 Funda Wang - 0.4.41-3 - adopt to new cmake macro -- Gitee