From: Ryosuke Saito <raitosyo@gmail.com>
To: meta-virtualization@lists.yoctoproject.org
Cc: ryosuke.saito@linaro.org
Subject: [meta-virtualization][PATCH] tini: Fix build error with CMake 4+
Date: Fri, 18 Jul 2025 18:12:53 +0900 [thread overview]
Message-ID: <20250718091253.829595-1-raitosyo@gmail.com> (raw)
From: Ryosuke Saito <ryosuke.saito@linaro.org>
Backport patches from https://github.com/krallin/tini to resolve the
build error with CMake 4.0 and later.
- 0001-chore-bump-minimum-CMake-to-2.8.12.patch
- 0001-chore-allow-CMake-though-to-3.10.patch
Signed-off-by: Ryosuke Saito <ryosuke.saito@linaro.org>
---
...001-chore-allow-CMake-though-to-3.10.patch | 39 +++++++++++++++++++
...1-chore-bump-minimum-CMake-to-2.8.12.patch | 29 ++++++++++++++
recipes-containers/tini/tini_0.19.0.bb | 2 +
3 files changed, 70 insertions(+)
create mode 100644 recipes-containers/tini/tini/0001-chore-allow-CMake-though-to-3.10.patch
create mode 100644 recipes-containers/tini/tini/0001-chore-bump-minimum-CMake-to-2.8.12.patch
diff --git a/recipes-containers/tini/tini/0001-chore-allow-CMake-though-to-3.10.patch b/recipes-containers/tini/tini/0001-chore-allow-CMake-though-to-3.10.patch
new file mode 100644
index 000000000000..faea9fb647f9
--- /dev/null
+++ b/recipes-containers/tini/tini/0001-chore-allow-CMake-though-to-3.10.patch
@@ -0,0 +1,39 @@
+From bb775aa14cc5072cf687fd7f4edd44df62c06b1d Mon Sep 17 00:00:00 2001
+From: Rudi Heitbaum <rudi@heitbaum.com>
+Date: Fri, 28 Mar 2025 19:10:02 +1100
+Subject: [PATCH] chore: allow CMake though to 3.10
+
+This is allows the build with cmake-4.0.0 without deprecation warnings.
+
+use min...max syntax to allow build with newer cmake.
+ref: https://cmake.org/cmake/help/latest/command/cmake_minimum_required.html
+
+Fixes:
+CMake Error at CMakeLists.txt:1 (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.
+
+Upstream-Status: Backport [https://github.com/krallin/tini/commit/071c715e376e9ee0ac1a196fe8c38bcb61ad385c]
+Signed-off-by: Ryosuke Saito <ryosuke.saito@linaro.org>
+---
+ CMakeLists.txt | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/CMakeLists.txt b/CMakeLists.txt
+index 9b06fc13f31d..2e5390b84967 100644
+--- a/CMakeLists.txt
++++ b/CMakeLists.txt
+@@ -1,4 +1,4 @@
+-cmake_minimum_required (VERSION 2.8.12)
++cmake_minimum_required (VERSION 2.8.12...3.10)
+ project (tini C)
+
+ # Config
+--
+2.34.1
+
diff --git a/recipes-containers/tini/tini/0001-chore-bump-minimum-CMake-to-2.8.12.patch b/recipes-containers/tini/tini/0001-chore-bump-minimum-CMake-to-2.8.12.patch
new file mode 100644
index 000000000000..ec03f7ff16b2
--- /dev/null
+++ b/recipes-containers/tini/tini/0001-chore-bump-minimum-CMake-to-2.8.12.patch
@@ -0,0 +1,29 @@
+From 0a5449a61b64938354db6efae8465d530d824d37 Mon Sep 17 00:00:00 2001
+From: Bjorn Neergaard <bneergaard@mirantis.com>
+Date: Fri, 27 Jan 2023 08:07:51 -0700
+Subject: [PATCH] chore: bump minimum CMake to 2.8.12
+
+This is both the last version supported by current CMake, and the
+version in use on Enterprise Linux 7.
+
+Signed-off-by: Bjorn Neergaard <bneergaard@mirantis.com>
+
+Upstream-Status: Backport [https://github.com/krallin/tini/commit/0b44d3665869e46ccbac7414241b8256d6234dc4]
+Signed-off-by: Ryosuke Saito <ryosuke.saito@linaro.org>
+---
+ CMakeLists.txt | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/CMakeLists.txt b/CMakeLists.txt
+index 4a6cab12fc25..9b06fc13f31d 100644
+--- a/CMakeLists.txt
++++ b/CMakeLists.txt
+@@ -1,4 +1,4 @@
+-cmake_minimum_required (VERSION 2.8.0)
++cmake_minimum_required (VERSION 2.8.12)
+ project (tini C)
+
+ # Config
+--
+2.34.1
+
diff --git a/recipes-containers/tini/tini_0.19.0.bb b/recipes-containers/tini/tini_0.19.0.bb
index c3ca25d07a4a..9eed4a646cba 100644
--- a/recipes-containers/tini/tini_0.19.0.bb
+++ b/recipes-containers/tini/tini_0.19.0.bb
@@ -10,6 +10,8 @@ SRC_URI = " \
file://0001-Do-not-strip-the-output-binary-allow-yocto-to-do-thi.patch \
file://0001-tini.c-a-function-declaration-without-a-prototype-is.patch \
file://0001-Support-POSIX-basename-from-musl-libc.patch \
+ file://0001-chore-bump-minimum-CMake-to-2.8.12.patch \
+ file://0001-chore-allow-CMake-though-to-3.10.patch \
"
LICENSE = "MIT"
--
2.50.0
next reply other threads:[~2025-07-18 9:13 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-07-18 9:12 Ryosuke Saito [this message]
2025-07-21 2:34 ` [meta-virtualization][PATCH] tini: Fix build error with CMake 4+ Bruce Ashfield
2025-07-21 3:19 ` Ryosuke Saito
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20250718091253.829595-1-raitosyo@gmail.com \
--to=raitosyo@gmail.com \
--cc=meta-virtualization@lists.yoctoproject.org \
--cc=ryosuke.saito@linaro.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.