public inbox for git-commits@fedoraproject.org
help / color / mirror / Atom feed
From: Alexander F. Lent <lx@xanderlent.com>
To: git-commits@fedoraproject.org
Subject: [rpms/openvino] origin/pr/7/head: Fix build against CMake 4.0.0 and later in rawhide
Date: Wed, 10 Jun 2026 16:59:18 GMT	[thread overview]
Message-ID: <178111075869.1.12400656767506068826.rpms-openvino-9339fade5e5b@fedoraproject.org> (raw)

            A new commit has been pushed.

            Repo   : rpms/openvino
            Branch : origin/pr/7/head
            Commit : 9339fade5e5b34aa3170ef655423d80e7f1c940d
            Author : Alexander F. Lent <lx@xanderlent.com>
            Date   : 2025-03-03T12:01:58+00:00
            Stats  : +18/-1 in 2 file(s)
            URL    : https://src.fedoraproject.org/rpms/openvino/c/9339fade5e5b34aa3170ef655423d80e7f1c940d?branch=origin/pr/7/head

            Log:
            Fix build against CMake 4.0.0 and later in rawhide

The bundled custom oneDNN sources have too old of a default CMake version.
CMake 4.0.0-rc2 and newer only support backwards compatability with 3.5 and newer.
So, patch the oneDNN sources to build under this constraint.

Signed-off-by: Alexander F. Lent <lx@xanderlent.com>

---
diff --git a/onednn-minimum-cmake-version.patch b/onednn-minimum-cmake-version.patch
new file mode 100644
index 0000000..7d6dd4a
--- /dev/null
+++ b/onednn-minimum-cmake-version.patch
@@ -0,0 +1,12 @@
+diff -ur a/src/plugins/intel_cpu/thirdparty/onednn/CMakeLists.txt b/src/plugins/intel_cpu/thirdparty/onednn/CMakeLists.txt
+--- a/src/plugins/intel_cpu/thirdparty/onednn/CMakeLists.txt	2024-10-24 07:23:20.000000000 -0400
++++ b/src/plugins/intel_cpu/thirdparty/onednn/CMakeLists.txt	2024-10-24 07:23:20.000000000 -0400
+@@ -14,7 +14,7 @@
+ # limitations under the License.
+ #===============================================================================
+ 
+-cmake_minimum_required(VERSION 2.8.12)
++cmake_minimum_required(VERSION 2.8.12...3.5)
+ 
+ if(POLICY CMP0022)
+     cmake_policy(SET CMP0022 NEW)

diff --git a/openvino.spec b/openvino.spec
index 3f803b4..1ad0243 100644
--- a/openvino.spec
+++ b/openvino.spec
@@ -51,6 +51,8 @@ Patch0:		openvino-fedora.patch
 Patch1:		https://github.com/openvinotoolkit/openvino/pull/28039.patch
 Patch2:		npu-level-zero.patch
 Patch3:		onnx-frontend-enable.patch
+# Fix the oneDNN build on CMake 4.0.0 and later
+Patch4:		onednn-minimum-cmake-version.patch
 
 ExclusiveArch:	x86_64
 
@@ -136,7 +138,8 @@ code. Python API provides bindings to basic and advanced APIs from OpenVINO
 runtime.
 
 %prep
-%autosetup -p1
+# autosetup without patching, since we need to patch one of the bundled libraries
+%autosetup -N
 
 # Remove the thirdparty deps
 rm -rf thirdparty/*
@@ -145,6 +148,8 @@ cp %{SOURCE4} thirdparty/
 # Intel-cpu-plugin thirdparty deps
 tar xf %{SOURCE1}
 cp -r oneDNN-*/* src/plugins/intel_cpu/thirdparty/onednn
+# autopatch will apply all the patches, now that we have unpacked enough of the bundled libraries
+%autopatch -p1
 tar xf %{SOURCE2}
 cp -r mlas-*/* src/plugins/intel_cpu/thirdparty/mlas
 

                 reply	other threads:[~2026-06-10 16:59 UTC|newest]

Thread overview: [no followups] expand[flat|nested]  mbox.gz  Atom feed

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=178111075869.1.12400656767506068826.rpms-openvino-9339fade5e5b@fedoraproject.org \
    --to=lx@xanderlent.com \
    --cc=git-commits@fedoraproject.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox