summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJan Palus2022-10-22 17:50:45 (GMT)
committerJan Palus2022-10-22 17:50:45 (GMT)
commit99af3ed487ccc392e504e62b4597b761ffbac691 (patch)
tree7bb04b9945a5c82e09a949b7266922d5b597d4ea
parenteacd362b7d9ac9eaade0d919694994ca7e9e79ad (diff)
downloadqt-creator-99af3ed487ccc392e504e62b4597b761ffbac691.zip
qt-creator-99af3ed487ccc392e504e62b4597b761ffbac691.tar.gz
upstream fix for llvm 15
-rw-r--r--llvm15.patch34
-rw-r--r--qt-creator.spec2
2 files changed, 36 insertions, 0 deletions
diff --git a/llvm15.patch b/llvm15.patch
new file mode 100644
index 0000000..3fe4fa6
--- /dev/null
+++ b/llvm15.patch
@@ -0,0 +1,34 @@
+From e238c8f0a4caf3d1487205093cffee9f56b56516 Mon Sep 17 00:00:00 2001
+From: =?UTF-8?q?Robert=20L=C3=B6hning?= <robert.loehning@qt.io>
+Date: Wed, 19 Oct 2022 10:49:14 +0200
+Subject: ClangFormat: Fix compilation with LLVM 15
+
+Change-Id: I7990e8331c317d3bc363be610b2585d37dee4445
+Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
+Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
+(cherry picked from commit a1bfcbf30d493e1e1fab94851fe50fed81cd3d6e)
+Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
+Reviewed-by: Eike Ziller <eike.ziller@qt.io>
+---
+ src/plugins/clangformat/clangformatutils.cpp | 4 ++++
+ 1 file changed, 4 insertions(+)
+
+diff --git a/src/plugins/clangformat/clangformatutils.cpp b/src/plugins/clangformat/clangformatutils.cpp
+index 230078558e..1e0429d80f 100644
+--- a/src/plugins/clangformat/clangformatutils.cpp
++++ b/src/plugins/clangformat/clangformatutils.cpp
+@@ -118,7 +118,11 @@ clang::format::FormatStyle qtcStyle()
+ style.ColumnLimit = 100;
+ style.CommentPragmas = "^ IWYU pragma:";
+ style.CompactNamespaces = false;
++#if LLVM_VERSION_MAJOR >= 15
++ style.PackConstructorInitializers = FormatStyle::PCIS_BinPack;
++#else
+ style.ConstructorInitializerAllOnOneLineOrOnePerLine = false;
++#endif
+ style.ConstructorInitializerIndentWidth = 4;
+ style.ContinuationIndentWidth = 4;
+ style.Cpp11BracedListStyle = true;
+--
+cgit v1.2.1
+
diff --git a/qt-creator.spec b/qt-creator.spec
index ee9e9dc..7fec4e4 100644
--- a/qt-creator.spec
+++ b/qt-creator.spec
@@ -8,6 +8,7 @@ License: LGPL v2.1
Group: X11/Development/Tools
Source0: https://download.qt.io/official_releases/qtcreator/8.0/%{version}/%{name}-opensource-src-%{version}.tar.xz
# Source0-md5: bdd73958efa2383a6a0953b81f48cc57
+Patch0: llvm15.patch
URL: https://doc.qt.io/qt-5/topics-app-development.html
BuildRequires: Qt5Concurrent-devel >= 5.9.0
BuildRequires: Qt5Designer-devel >= 5.9.0
@@ -55,6 +56,7 @@ Qt.
%prep
%setup -q -n %{name}-opensource-src-%{version}
+%patch0 -p1
sed -i '1s|^#!.*python\b|#!%{__python}|' src/shared/qbs/src/3rdparty/python/bin/dmgbuild