]> git.ipfire.org Git - ipfire-2.x.git/commitdiff
transmission: Update to CMakeLists.txt of min cmake version
authorAdolf Belka <adolf.belka@ipfire.org>
Sun, 11 May 2025 10:13:04 +0000 (12:13 +0200)
committerMichael Tremer <michael.tremer@ipfire.org>
Mon, 12 May 2025 14:41:27 +0000 (14:41 +0000)
- The main CMakeLists.txt was okay but a lot of the CMakeLists.txt files in the third
   part folder had min version prior to 3.5
- A patch set has been made in the transmission source but it was also changing a lot of
   other things. I just created my own patch to update the files in the third party
   folder and the build was successfull with that.
- If a new version is released then this patch can be removed but it will depend on
   if that new version includes the fix to the bug in 4.0.6 that has resulted in a
   variety of torrent mirrors banning transmission-4.0.6. This caused the transmission
   update in IPFire to be reverted to 4.0.5

Signed-off-by: Adolf Belka <adolf.belka@ipfire.org>
Signed-off-by: Michael Tremer <michael.tremer@ipfire.org>
lfs/transmission
src/patches/transmission-4.0.5-allow_build_with_cmake-4.0.x.patch [new file with mode: 0644]

index c95c8b37369f3178f8b699baab61f9fed7f6e42d..bbc8de19c3b5885a63e969aa5e5a9f43a545baf4 100644 (file)
@@ -1,7 +1,7 @@
 ###############################################################################
 #                                                                             #
 # IPFire.org - A linux based firewall                                         #
-# Copyright (C) 2007-2024  IPFire Team  <info@ipfire.org>                     #
+# Copyright (C) 2007-2025  IPFire Team  <info@ipfire.org>                     #
 #                                                                             #
 # This program is free software: you can redistribute it and/or modify        #
 # it under the terms of the GNU General Public License as published by        #
@@ -34,7 +34,7 @@ DL_FROM    = $(URL_IPFIRE)
 DIR_APP    = $(DIR_SRC)/$(THISAPP)
 TARGET     = $(DIR_INFO)/$(THISAPP)
 PROG       = transmission
-PAK_VER    = 25
+PAK_VER    = 26
 
 DEPS       =
 
@@ -81,6 +81,7 @@ $(subst %,%_BLAKE2,$(objects)) :
 $(TARGET) : $(patsubst %,$(DIR_DL)/%,$(objects))
        @$(PREBUILD)
        @rm -rf $(DIR_APP) && cd $(DIR_SRC) && tar axf $(DIR_DL)/$(DL_FILE)
+       cd $(DIR_APP) && patch -Np1 -i $(DIR_SRC)/src/patches/transmission-4.0.5-allow_build_with_cmake-4.0.x.patch
        cd $(DIR_APP) && cmake . \
                        -DCMAKE_INSTALL_PREFIX=/usr \
                        -DCMAKE_BUILD_TYPE=Release \
diff --git a/src/patches/transmission-4.0.5-allow_build_with_cmake-4.0.x.patch b/src/patches/transmission-4.0.5-allow_build_with_cmake-4.0.x.patch
new file mode 100644 (file)
index 0000000..8dbb3d3
--- /dev/null
@@ -0,0 +1,117 @@
+diff -Naur transmission-4.0.5.orig/third-party/dht/CMakeLists.txt transmission-4.0.5/third-party/dht/CMakeLists.txt
+--- transmission-4.0.5.orig/third-party/dht/CMakeLists.txt     2023-12-07 00:14:35.000000000 +0100
++++ transmission-4.0.5/third-party/dht/CMakeLists.txt  2025-05-08 21:06:46.228619936 +0200
+@@ -1,4 +1,4 @@
+-cmake_minimum_required(VERSION 2.8)
++cmake_minimum_required(VERSION 3.10)
+ project(dht C)
+ add_library(${PROJECT_NAME} STATIC
+diff -Naur transmission-4.0.5.orig/third-party/fast_float/CMakeLists.txt transmission-4.0.5/third-party/fast_float/CMakeLists.txt
+--- transmission-4.0.5.orig/third-party/fast_float/CMakeLists.txt      2023-12-07 00:14:35.000000000 +0100
++++ transmission-4.0.5/third-party/fast_float/CMakeLists.txt   2025-05-08 21:07:00.907066965 +0200
+@@ -1,4 +1,4 @@
+-cmake_minimum_required(VERSION 3.9)
++cmake_minimum_required(VERSION 3.10)
+ project(fast_float VERSION 3.4.0 LANGUAGES CXX)
+ option(FASTFLOAT_TEST "Enable tests" OFF)
+diff -Naur transmission-4.0.5.orig/third-party/fmt/CMakeLists.txt transmission-4.0.5/third-party/fmt/CMakeLists.txt
+--- transmission-4.0.5.orig/third-party/fmt/CMakeLists.txt     2023-12-07 00:14:35.000000000 +0100
++++ transmission-4.0.5/third-party/fmt/CMakeLists.txt  2025-05-08 21:07:41.135292083 +0200
+@@ -1,4 +1,4 @@
+-cmake_minimum_required(VERSION 3.1...3.18)
++cmake_minimum_required(VERSION 3.10...3.18)
+ # Fallback for using newer policies on CMake <3.12.
+ if(${CMAKE_VERSION} VERSION_LESS 3.12)
+diff -Naur transmission-4.0.5.orig/third-party/googletest/CMakeLists.txt transmission-4.0.5/third-party/googletest/CMakeLists.txt
+--- transmission-4.0.5.orig/third-party/googletest/CMakeLists.txt      2023-12-07 00:14:35.000000000 +0100
++++ transmission-4.0.5/third-party/googletest/CMakeLists.txt   2025-05-08 21:08:06.835074741 +0200
+@@ -1,7 +1,7 @@
+ # Note: CMake support is community-based. The maintainers do not use CMake
+ # internally.
+-cmake_minimum_required(VERSION 3.5)
++cmake_minimum_required(VERSION 3.10)
+ if (POLICY CMP0048)
+   cmake_policy(SET CMP0048 NEW)
+diff -Naur transmission-4.0.5.orig/third-party/libb64/CMakeLists.txt transmission-4.0.5/third-party/libb64/CMakeLists.txt
+--- transmission-4.0.5.orig/third-party/libb64/CMakeLists.txt  2023-12-07 00:14:35.000000000 +0100
++++ transmission-4.0.5/third-party/libb64/CMakeLists.txt       2025-05-08 21:08:40.035085810 +0200
+@@ -1,4 +1,4 @@
+-cmake_minimum_required(VERSION 3.5 FATAL_ERROR)
++cmake_minimum_required(VERSION 3.10 FATAL_ERROR)
+ project(libb64 VERSION 2.0.0 LANGUAGES C)
+ set(LIBB64_STANDALONE_BUILD OFF)
+diff -Naur transmission-4.0.5.orig/third-party/libdeflate/CMakeLists.txt transmission-4.0.5/third-party/libdeflate/CMakeLists.txt
+--- transmission-4.0.5.orig/third-party/libdeflate/CMakeLists.txt      2023-12-07 00:14:35.000000000 +0100
++++ transmission-4.0.5/third-party/libdeflate/CMakeLists.txt   2025-05-08 21:08:58.870659428 +0200
+@@ -1,4 +1,4 @@
+-cmake_minimum_required(VERSION 3.7)
++cmake_minimum_required(VERSION 3.10)
+ # Default to a release build.
+ if(NOT CMAKE_BUILD_TYPE AND NOT CMAKE_CONFIGURATION_TYPES)
+diff -Naur transmission-4.0.5.orig/third-party/libevent/CMakeLists.txt transmission-4.0.5/third-party/libevent/CMakeLists.txt
+--- transmission-4.0.5.orig/third-party/libevent/CMakeLists.txt        2023-12-07 00:14:35.000000000 +0100
++++ transmission-4.0.5/third-party/libevent/CMakeLists.txt     2025-05-08 21:09:27.056517789 +0200
+@@ -19,7 +19,7 @@
+ #       start libevent.sln
+ #
+-cmake_minimum_required(VERSION 3.1 FATAL_ERROR)
++cmake_minimum_required(VERSION 3.10 FATAL_ERROR)
+ if (POLICY CMP0054)
+     cmake_policy(SET CMP0054 NEW)
+diff -Naur transmission-4.0.5.orig/third-party/libnatpmp/CMakeLists.txt transmission-4.0.5/third-party/libnatpmp/CMakeLists.txt
+--- transmission-4.0.5.orig/third-party/libnatpmp/CMakeLists.txt       2023-12-07 00:14:35.000000000 +0100
++++ transmission-4.0.5/third-party/libnatpmp/CMakeLists.txt    2025-05-08 21:09:46.043096005 +0200
+@@ -1,4 +1,4 @@
+-cmake_minimum_required(VERSION 2.8)
++cmake_minimum_required(VERSION 3.10)
+ project(natpmp C)
+ add_definitions(-DNATPMP_STATICLIB -DENABLE_STRNATPMPERR)
+diff -Naur transmission-4.0.5.orig/third-party/libpsl/CMakeLists.txt transmission-4.0.5/third-party/libpsl/CMakeLists.txt
+--- transmission-4.0.5.orig/third-party/libpsl/CMakeLists.txt  2023-12-07 00:14:35.000000000 +0100
++++ transmission-4.0.5/third-party/libpsl/CMakeLists.txt       2025-05-08 21:09:59.844516650 +0200
+@@ -2,7 +2,7 @@
+ # This is just the minimum subset needed for building an embedded
+ # static library into Transmission.
+-cmake_minimum_required(VERSION 3.0)
++cmake_minimum_required(VERSION 3.10)
+ project(psl
+   VERSION 0.21.1.0 # when changing this, must set LIBPSL_VERSION_NUMBER too
+diff -Naur transmission-4.0.5.orig/third-party/libutp/CMakeLists.txt transmission-4.0.5/third-party/libutp/CMakeLists.txt
+--- transmission-4.0.5.orig/third-party/libutp/CMakeLists.txt  2023-12-07 00:14:36.000000000 +0100
++++ transmission-4.0.5/third-party/libutp/CMakeLists.txt       2025-05-08 21:10:25.155290353 +0200
+@@ -1,4 +1,4 @@
+-cmake_minimum_required(VERSION 3.5 FATAL_ERROR)
++cmake_minimum_required(VERSION 3.10 FATAL_ERROR)
+ project(libutp VERSION 3.4 LANGUAGES C CXX)
+ set(LIBUTP_STANDALONE_BUILD OFF)
+diff -Naur transmission-4.0.5.orig/third-party/miniupnpc/CMakeLists.txt transmission-4.0.5/third-party/miniupnpc/CMakeLists.txt
+--- transmission-4.0.5.orig/third-party/miniupnpc/CMakeLists.txt       2023-12-07 00:14:36.000000000 +0100
++++ transmission-4.0.5/third-party/miniupnpc/CMakeLists.txt    2025-05-08 21:10:44.852892384 +0200
+@@ -1,4 +1,4 @@
+-cmake_minimum_required (VERSION 2.6)
++cmake_minimum_required (VERSION 3.10)
+ project (miniupnpc C)
+ set (MINIUPNPC_VERSION 2.0)
+diff -Naur transmission-4.0.5.orig/third-party/utfcpp/CMakeLists.txt transmission-4.0.5/third-party/utfcpp/CMakeLists.txt
+--- transmission-4.0.5.orig/third-party/utfcpp/CMakeLists.txt  2023-12-07 00:14:36.000000000 +0100
++++ transmission-4.0.5/third-party/utfcpp/CMakeLists.txt       2025-05-08 21:10:59.986354870 +0200
+@@ -1,4 +1,4 @@
+-cmake_minimum_required (VERSION 3.0.2)
++cmake_minimum_required (VERSION 3.10)
+ project (utf8cpp VERSION 3.2 LANGUAGES CXX)
+ if(CMAKE_SOURCE_DIR STREQUAL CMAKE_CURRENT_SOURCE_DIR)