public inbox for git-commits@fedoraproject.org
help / color / mirror / Atom feed
From: Jan Grulich <jgrulich@redhat.com>
To: git-commits@fedoraproject.org
Subject: [rpms/qt-creator] epel9: Fix build against Qt 6.9.2
Date: Thu, 08 Oct 2026 20:59:22 GMT	[thread overview]
Message-ID: <179149316239.1.8299852091945290913.rpms-qt-creator-f6791e25a4ad@fedoraproject.org> (raw)

A new commit has been pushed.

Repo   : rpms/qt-creator
Branch : epel9
Commit : f6791e25a4ad662ad881e9c8b0fa046c1e8bda23
Author : Jan Grulich <jgrulich@redhat.com>
Date   : 2025-09-09T19:07:53+02:00
Stats  : +50/-0 in 2 file(s)
URL    : https://src.fedoraproject.org/rpms/qt-creator/c/f6791e25a4ad662ad881e9c8b0fa046c1e8bda23?branch=epel9

Log:
Fix build against Qt 6.9.2

---
diff --git a/qt-creator-stringtable-adapt-to-qarraydata-member-name-change.patch b/qt-creator-stringtable-adapt-to-qarraydata-member-name-change.patch
new file mode 100644
index 0000000..e126d98
--- /dev/null
+++ b/qt-creator-stringtable-adapt-to-qarraydata-member-name-change.patch
@@ -0,0 +1,48 @@
+From 04e6e631b2689f07a91bd753911d67a90d36e18c Mon Sep 17 00:00:00 2001
+From: Marc Mutz <marc.mutz@qt.io>
+Date: Thu, 10 Jul 2025 07:17:48 +0200
+Subject: [PATCH] StringTable: adapt to QArrayData member name change
+
+The implementation (in unconditionally-disabled debug code) inspected
+QArrayData::ref_, which
+qtbase/3f61f736266ece40d627dcf6214618a22a009fd1 recently renamed to
+m_ref in order to catch exactly such out-of-tree users.
+
+While a re-rename is being merged to qtbase, unblock QtCreator by
+writing a little helper to extract the member under either name, using
+Expression SFINAE.
+
+As a drive-by, change the implicit Q*Atomc::loadAcquire() into a
+loadRelaxed(), which is sufficient here, because the code just does
+calculations on the ref-count number, it needs no memory ordering.
+
+Change-Id: Ib9351e1251fc393f8f92ca6076fa725141d396e8
+Reviewed-by: hjk <hjk@qt.io>
+---
+ src/libs/utils/stringtable.cpp | 9 ++++++++-
+ 1 file changed, 8 insertions(+), 1 deletion(-)
+
+diff --git a/src/libs/utils/stringtable.cpp b/src/libs/utils/stringtable.cpp
+index 61d49f6a..ed269456 100644
+--- a/src/libs/utils/stringtable.cpp
++++ b/src/libs/utils/stringtable.cpp
+@@ -92,11 +92,18 @@ QTCREATOR_UTILS_EXPORT void scheduleGC()
+ 
+ static int bytesSaved = 0;
+ 
++// qtbase/3f61f736266ece40d627dcf6214618a22a009fd1 changed QArrayData::{ref_ → m_ref};
++// adapt:
++template <typename S>
++auto getQArrayDataRef(const S *s) -> decltype(s->ref_) { return s->ref_.loadRelaxed(); }
++template <typename S>
++auto getQArrayDataRef(const S *s) -> decltype(s->m_ref) { return s->m_ref.loadRelaxed(); }
++
+ static inline bool isQStringInUse(const QString &string)
+ {
+     if (DebugStringTable) {
+         QStringPrivate &data_ptr = const_cast<QString&>(string).data_ptr();
+-        const int ref = data_ptr->d_ptr()->ref_;
++        const int ref = getQArrayDataRef(data_ptr->d_ptr());
+         bytesSaved += (ref - 1) * string.size();
+         if (ref > 10)
+             qDebug() << ref << string.size() << string.left(50);

diff --git a/qt-creator.spec b/qt-creator.spec
index 4aa577d..5b2a5b5 100644
--- a/qt-creator.spec
+++ b/qt-creator.spec
@@ -23,6 +23,8 @@ Patch3:         qt-creator-debuginfod.patch
 # Drop refereces to unbundled yaml-cpp
 Patch4:         qt-creator_unbundle.patch
 
+Patch10:        qt-creator-stringtable-adapt-to-qarraydata-member-name-change.patch
+
 BuildRequires:  chrpath
 BuildRequires:  cmake
 #BuildRequires:  cmake(KF5SyntaxHighlighting)

                 reply	other threads:[~2026-10-08 20: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=179149316239.1.8299852091945290913.rpms-qt-creator-f6791e25a4ad@fedoraproject.org \
    --to=jgrulich@redhat.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