Merge lp:~zeller-benjamin/kubuntu-packaging/fixcmakeagain into lp:~kubuntu-packagers/kubuntu-packaging/qtcreator

Proposed by Benjamin Zeller
Status: Merged
Merged at revision: 164
Proposed branch: lp:~zeller-benjamin/kubuntu-packaging/fixcmakeagain
Merge into: lp:~kubuntu-packagers/kubuntu-packaging/qtcreator
Diff against target: 118 lines (+53/-16)
1 file modified
debian/patches/cmake_ubuntuspecificbits.diff (+53/-16)
To merge this branch: bzr merge lp:~zeller-benjamin/kubuntu-packaging/fixcmakeagain
Reviewer Review Type Date Requested Status
Zoltan Balogh (community) Approve
Timo Jyrinki Pending
Review via email: mp+269623@code.launchpad.net

Commit message

Fixes Bug lp:1489331 "Complains about not being able to find custom executable when trying to run application"

Description of the change

Fixes Bug lp:1489331 "Complains about not being able to find custom executable when trying to run application"

To post a comment you must log in.
Revision history for this message
Zoltan Balogh (bzoltan) wrote :

OK

review: Approve

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1=== modified file 'debian/patches/cmake_ubuntuspecificbits.diff'
2--- debian/patches/cmake_ubuntuspecificbits.diff 2015-06-04 08:56:32 +0000
3+++ debian/patches/cmake_ubuntuspecificbits.diff 2015-08-31 09:29:07 +0000
4@@ -1,8 +1,6 @@
5-diff --git a/src/plugins/cmakeprojectmanager/cmakeprojectmanager.cpp b/src/plugins/cmakeprojectmanager/cmakeprojectmanager.cpp
6-index 476d3da..bdf2c47 100644
7 --- a/src/plugins/cmakeprojectmanager/cmakeprojectmanager.cpp
8 +++ b/src/plugins/cmakeprojectmanager/cmakeprojectmanager.cpp
9-@@ -148,10 +148,10 @@ void CMakeManager::createXmlFile(Utils::QtcProcess *proc, const QString &executa
10+@@ -148,10 +148,10 @@
11 proc->setWorkingDirectory(buildDirectoryPath);
12 proc->setEnvironment(env);
13
14@@ -16,11 +14,9 @@
15 Utils::QtcProcess::addArgs(&args, arguments);
16 Utils::QtcProcess::addArg(&args, generator);
17 proc->setCommand(executable, args);
18-diff --git a/src/plugins/cmakeprojectmanager/generatorinfo.cpp b/src/plugins/cmakeprojectmanager/generatorinfo.cpp
19-index e3c5a38..9f2bdc8 100644
20 --- a/src/plugins/cmakeprojectmanager/generatorinfo.cpp
21 +++ b/src/plugins/cmakeprojectmanager/generatorinfo.cpp
22-@@ -130,7 +130,8 @@ QList<GeneratorInfo> GeneratorInfo::generatorInfosFor(ProjectExplorer::Kit *k, N
23+@@ -132,7 +132,8 @@
24 if (deviceType != ProjectExplorer::Constants::DESKTOP_DEVICE_TYPE
25 && deviceType != BareMetal::Constants::BareMetalOsType
26 && deviceType != RemoteLinux::Constants::GenericLinuxOsType
27@@ -30,11 +26,9 @@
28 return results;
29 ProjectExplorer::Abi targetAbi = tc->targetAbi();
30 if (n != ForceNinja) {
31-diff --git a/src/plugins/qmakeprojectmanager/qmakenodes.cpp b/src/plugins/qmakeprojectmanager/qmakenodes.cpp
32-index 7de1327..558ec8f 100644
33 --- a/src/plugins/qmakeprojectmanager/qmakenodes.cpp
34 +++ b/src/plugins/qmakeprojectmanager/qmakenodes.cpp
35-@@ -1950,6 +1950,7 @@ EvalResult *QmakeProFileNode::evaluate(const EvalInput &input)
36+@@ -1938,6 +1938,7 @@
37 result->newVarValues[AndroidPackageSourceDir] = input.readerExact->values(QLatin1String("ANDROID_PACKAGE_SOURCE_DIR"));
38 result->newVarValues[AndroidExtraLibs] = input.readerExact->values(QLatin1String("ANDROID_EXTRA_LIBS"));
39 result->newVarValues[IsoIconsVar] = input.readerExact->values(QLatin1String("ISO_ICONS"));
40@@ -42,11 +36,9 @@
41
42 result->isDeployable = false;
43 if (result->projectType == ApplicationTemplate) {
44-diff --git a/src/plugins/qmakeprojectmanager/qmakenodes.h b/src/plugins/qmakeprojectmanager/qmakenodes.h
45-index c33e70d..ebd3b9a 100644
46 --- a/src/plugins/qmakeprojectmanager/qmakenodes.h
47 +++ b/src/plugins/qmakeprojectmanager/qmakenodes.h
48-@@ -110,7 +110,8 @@ enum QmakeVariable {
49+@@ -110,7 +110,8 @@
50 AndroidDeploySettingsFile,
51 AndroidPackageSourceDir,
52 AndroidExtraLibs,
53@@ -56,11 +48,9 @@
54 };
55
56 namespace Internal {
57-diff --git a/src/plugins/qmlprojectmanager/qmlproject.cpp b/src/plugins/qmlprojectmanager/qmlproject.cpp
58-index 435918a..4956d46 100644
59 --- a/src/plugins/qmlprojectmanager/qmlproject.cpp
60 +++ b/src/plugins/qmlprojectmanager/qmlproject.cpp
61-@@ -305,9 +305,10 @@ IProjectManager *QmlProject::projectManager() const
62+@@ -305,9 +305,10 @@
63 bool QmlProject::supportsKit(Kit *k, QString *errorMessage) const
64 {
65 Id deviceType = DeviceTypeKitInformation::deviceTypeId(k);
66@@ -73,4 +63,51 @@
67 return false;
68 }
69
70-
71+--- a/src/plugins/cmakeprojectmanager/cmakeproject.cpp
72++++ b/src/plugins/cmakeprojectmanager/cmakeproject.cpp
73+@@ -630,16 +630,14 @@
74+ // TODO Compare with updateDefaultRunConfigurations();
75+ void CMakeProject::updateRunConfigurations(Target *t)
76+ {
77++ // create new and remove obsolete RCs using the factories
78++ t->updateDefaultRunConfigurations();
79++
80+ // *Update* runconfigurations:
81+ QMultiMap<QString, CMakeRunConfiguration*> existingRunConfigurations;
82+- QList<ProjectExplorer::RunConfiguration *> toRemove;
83+ foreach (ProjectExplorer::RunConfiguration *rc, t->runConfigurations()) {
84+ if (CMakeRunConfiguration* cmakeRC = qobject_cast<CMakeRunConfiguration *>(rc))
85+ existingRunConfigurations.insert(cmakeRC->title(), cmakeRC);
86+- QtSupport::CustomExecutableRunConfiguration *ceRC =
87+- qobject_cast<QtSupport::CustomExecutableRunConfiguration *>(rc);
88+- if (ceRC && !ceRC->isConfigured())
89+- toRemove << rc;
90+ }
91+
92+ foreach (const CMakeBuildTarget &ct, buildTargets()) {
93+@@ -656,14 +654,9 @@
94+ rc->setEnabled(true);
95+ }
96+ existingRunConfigurations.remove(ct.title);
97+- } else {
98+- // Does not exist yet
99+- Core::Id id = CMakeRunConfigurationFactory::idFromBuildTarget(ct.title);
100+- CMakeRunConfiguration *rc = new CMakeRunConfiguration(t, id, ct.executable,
101+- ct.workingDirectory, ct.title);
102+- t->addRunConfiguration(rc);
103+ }
104+ }
105++
106+ QMultiMap<QString, CMakeRunConfiguration *>::const_iterator it =
107+ existingRunConfigurations.constBegin();
108+ for ( ; it != existingRunConfigurations.constEnd(); ++it) {
109+@@ -674,9 +667,6 @@
110+ // removeRunConfiguration(rc);
111+ }
112+
113+- foreach (ProjectExplorer::RunConfiguration *rc, toRemove)
114+- t->removeRunConfiguration(rc);
115+-
116+ if (t->runConfigurations().isEmpty()) {
117+ // Oh no, no run configuration,
118+ // create a custom executable run configuration

Subscribers

People subscribed via source and target branches