Fix Clang plugin patch

This commit is contained in:
Rodrigo Bezerra
2019-05-03 17:13:22 -03:00
parent 38a0ccfda2
commit 2e53efd6e2
3 changed files with 26 additions and 30 deletions

View File

@@ -1,6 +1,6 @@
pkgbase = qtcreator-git
pkgdesc = Lightweight, cross-platform integrated development environment
pkgver = v4.9.0.rc1.r328.ged87b74a59
pkgver = v4.9.0.r473.g1de548d1cb
pkgrel = 1
url = https://www.qt.io
arch = x86_64
@@ -38,7 +38,7 @@ pkgbase = qtcreator-git
source = qtcreator-clang-plugins.patch
sha256sums = SKIP
sha256sums = SKIP
sha256sums = 955e2ec0de1ea0fd2994d04dfb9a04e74513e4f3fe189e76dd4a256fd9c864eb
sha256sums = 26382c282c36aa6716af2deadae864ed21ffba0dd568f9b8f8f8048ce304f436
pkgname = qtcreator-git

View File

@@ -8,7 +8,7 @@
# Contributor: Tobias Hunger <tobias dot hunger at gmail dot com>
pkgname=qtcreator-git
pkgver=v4.9.0.rc1.r328.ged87b74a59
pkgver=v4.9.0.r473.g1de548d1cb
pkgrel=1
pkgdesc='Lightweight, cross-platform integrated development environment'
arch=('x86_64')
@@ -36,7 +36,7 @@ source=('git+https://code.qt.io/qt-creator/qt-creator.git'
'qtcreator-clang-plugins.patch')
sha256sums=('SKIP'
'SKIP'
'955e2ec0de1ea0fd2994d04dfb9a04e74513e4f3fe189e76dd4a256fd9c864eb')
'26382c282c36aa6716af2deadae864ed21ffba0dd568f9b8f8f8048ce304f436')
pkgver() {
cd qt-creator

View File

@@ -1,8 +1,7 @@
diff --git a/src/plugins/clangcodemodel/clangeditordocumentprocessor.cpp b/src/plugins/clangcodemodel/clangeditordocumentprocessor.cpp
index 706c5101a3..0f7af62dba 100644
--- a/src/plugins/clangcodemodel/clangeditordocumentprocessor.cpp
+++ b/src/plugins/clangcodemodel/clangeditordocumentprocessor.cpp
@@ -511,6 +511,7 @@ private:
diff '--color=auto' --unified --recursive --text qt-creator.orig/src/plugins/clangcodemodel/clangeditordocumentprocessor.cpp qt-creator.new/src/plugins/clangcodemodel/clangeditordocumentprocessor.cpp
--- qt-creator.orig/src/plugins/clangcodemodel/clangeditordocumentprocessor.cpp 2019-05-03 16:09:59.000000000 -0300
+++ qt-creator.new/src/plugins/clangcodemodel/clangeditordocumentprocessor.cpp 2019-05-03 15:57:36.000000000 -0300
@@ -511,6 +511,7 @@
if (tidyMode == Mode::Disabled)
return;
@@ -10,22 +9,21 @@ index 706c5101a3..0f7af62dba 100644
m_options.append(CppTools::XclangArgs({"-add-plugin", "clang-tidy"}));
if (tidyMode == Mode::File)
@@ -526,8 +527,8 @@ private:
@@ -526,8 +527,8 @@
if (checks.isEmpty())
return;
- m_options.append(CppTools::XclangArgs({"-add-plugin",
- "clang-lazy",
- "clazy",
+ m_options.append(CppTools::XclangArgs({"-load", "ClazyPlugin.so",
+ "-add-plugin", "clazy",
"-plugin-arg-clang-lazy",
"-plugin-arg-clazy",
"enable-all-fixits",
"-plugin-arg-clang-lazy",
diff --git a/src/plugins/clangtools/clangtidyclazyrunner.cpp b/src/plugins/clangtools/clangtidyclazyrunner.cpp
index a580704243..42c4319240 100644
--- a/src/plugins/clangtools/clangtidyclazyrunner.cpp
+++ b/src/plugins/clangtools/clangtidyclazyrunner.cpp
@@ -76,6 +76,7 @@ QStringList ClangTidyClazyRunner::constructCommandLineArguments(const QStringLis
"-plugin-arg-clazy",
diff '--color=auto' --unified --recursive --text qt-creator.orig/src/plugins/clangtools/clangtidyclazyrunner.cpp qt-creator.new/src/plugins/clangtools/clangtidyclazyrunner.cpp
--- qt-creator.orig/src/plugins/clangtools/clangtidyclazyrunner.cpp 2019-05-03 16:09:59.000000000 -0300
+++ qt-creator.new/src/plugins/clangtools/clangtidyclazyrunner.cpp 2019-05-03 16:02:39.000000000 -0300
@@ -76,6 +76,7 @@
const ClangDiagnosticConfig::TidyMode tidyMode = m_diagnosticConfig.clangTidyMode();
if (tidyMode != ClangDiagnosticConfig::TidyMode::Disabled) {
@@ -33,15 +31,13 @@ index a580704243..42c4319240 100644
arguments << XclangArgs({"-add-plugin", "clang-tidy"});
if (tidyMode != ClangDiagnosticConfig::TidyMode::File) {
const QString tidyChecks = m_diagnosticConfig.clangTidyChecks();
@@ -85,8 +86,9 @@ QStringList ClangTidyClazyRunner::constructCommandLineArguments(const QStringLis
@@ -85,7 +86,8 @@
const QString clazyChecks = m_diagnosticConfig.clazyChecks();
if (!clazyChecks.isEmpty()) {
- arguments << XclangArgs({"-add-plugin",
- "clang-lazy",
+ arguments << XclangArgs({"-load", "ClazyPlugin.so",
+ "-add-plugin",
+ "clazy",
"-plugin-arg-clang-lazy",
"clazy",
"-plugin-arg-clazy",
"enable-all-fixits",
"-plugin-arg-clang-lazy",