summaryrefslogtreecommitdiff
path: root/dev-cpp/yaml-cpp/files/yaml-cpp-0.8.0-cmake.patch
diff options
context:
space:
mode:
authorAlexey Sokolov <alexey+gentoo@asokolov.org>2025-03-22 21:31:58 +0000
committerSam James <sam@gentoo.org>2025-03-25 04:34:56 +0000
commit6e886a60292fb9223414b29aa5aac97e79e289b0 (patch)
tree5a69a4898462ae1bb9b1f844878fdd470808d31a /dev-cpp/yaml-cpp/files/yaml-cpp-0.8.0-cmake.patch
parent44c3b0ad1f11ef69078f59527bb5df665f8cae6a (diff)
downloadgentoo-6e886a60292fb9223414b29aa5aac97e79e289b0.tar.gz
gentoo-6e886a60292fb9223414b29aa5aac97e79e289b0.tar.bz2
gentoo-6e886a60292fb9223414b29aa5aac97e79e289b0.zip
dev-cpp/yaml-cpp: fix cmake warning
Closes: https://bugs.gentoo.org/951842 Signed-off-by: Alexey Sokolov <alexey+gentoo@asokolov.org> Closes: https://github.com/gentoo/gentoo/pull/41226 Signed-off-by: Sam James <sam@gentoo.org>
Diffstat (limited to 'dev-cpp/yaml-cpp/files/yaml-cpp-0.8.0-cmake.patch')
-rw-r--r--dev-cpp/yaml-cpp/files/yaml-cpp-0.8.0-cmake.patch32
1 files changed, 32 insertions, 0 deletions
diff --git a/dev-cpp/yaml-cpp/files/yaml-cpp-0.8.0-cmake.patch b/dev-cpp/yaml-cpp/files/yaml-cpp-0.8.0-cmake.patch
new file mode 100644
index 000000000000..52c6321983d7
--- /dev/null
+++ b/dev-cpp/yaml-cpp/files/yaml-cpp-0.8.0-cmake.patch
@@ -0,0 +1,32 @@
+https://bugs.gentoo.org/951842
+https://github.com/jbeder/yaml-cpp/pull/1211
+
+From 8153a1add19018f65527faad3c4d3941705baf39 Mon Sep 17 00:00:00 2001
+From: Craig Scott <craig.scott@crascit.com>
+Date: Wed, 16 Aug 2023 15:55:44 +1000
+Subject: [PATCH] Specify CMake policy range to avoid deprecation warning
+
+CMake 3.27 started issuing a deprecation warning for any
+cmake_minimum_required() call that specified a minimum
+version older than 3.5. Specifying a version range instead of
+a simple minimum version avoids that warning without
+raising the minimum supported CMake version. The NEW
+policy behavior will be used for all policies introduced up to
+CMake 3.14 with this change.
+---
+ CMakeLists.txt | 5 +++--
+ 1 file changed, 3 insertions(+), 2 deletions(-)
+
+diff --git a/CMakeLists.txt b/CMakeLists.txt
+index 46dc18059..1ae92e2b7 100644
+--- a/CMakeLists.txt
++++ b/CMakeLists.txt
+@@ -1,5 +1,6 @@
+-# 3.5 is actually available almost everywhere, but this a good minimum
+-cmake_minimum_required(VERSION 3.4)
++# 3.5 is actually available almost everywhere, but this a good minimum.
++# 3.14 as the upper policy limit avoids CMake deprecation warnings.
++cmake_minimum_required(VERSION 3.4...3.14)
+
+ # enable MSVC_RUNTIME_LIBRARY target property
+ # see https://cmake.org/cmake/help/latest/policy/CMP0091.html