Commit Graph

19 Commits

Author SHA1 Message Date
Tobias Hunger
88438a0e79 CMake: Small simplification
Change-Id: Ib89f95febeb45628e99e3c6a473853da4dcde3d0
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
2018-06-29 13:41:49 +00:00
Tobias Hunger
8128d89a0b CMake: Remove cmake autodetectionhelpers
No user in-tree and the Ubuntu SDK for which this code was added
is no more.

Change-Id: I5b0c5f6faccf1adb451c4043378a204bfc350e50
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
2018-06-27 13:07:43 +00:00
Tobias Hunger
73f617ab34 CMake: Simplify code
Emit signal in addCMakeTool method directly instead of later.

Change-Id: I4640ffdf76d22f80a8c1ee14f8d79cc7885ddd70
Reviewed-by: Tim Jenssen <tim.jenssen@qt.io>
2018-06-01 14:03:19 +00:00
Eike Ziller
f42ea09b74 Do not construct settings/resource paths from QSettings object
These paths are controlled by ICore.

Add ICore::installerResourcePath() to replace constructions with
settings(SystemScope)
Replace constructions with settings()->fileName() by usage of
ICore::userResourcePath().

Change-Id: I5a9fa9d09f2563c39dc5d11a4586da825c62f9ac
Reviewed-by: Tobias Hunger <tobias.hunger@qt.io>
2018-01-11 10:42:09 +00:00
Tobias Hunger
3d8be750b9 Environment: Use Utils::FileName for path() and related methods
Update users accordingly.

Change-Id: I9432e82308e9d0630514c6c8632aeb6b6ee0cf90
Reviewed-by: Tim Jenssen <tim.jenssen@qt.io>
2017-09-27 07:37:26 +00:00
Orgad Shaneh
f10af21922 CMake: Fix auto-detection on Windows
Recent CMake installer (3.9) installs the executable in CMake/bin.

Change-Id: I3912badc0907c91044e76b3155e924dd985819f1
Reviewed-by: Tobias Hunger <tobias.hunger@qt.io>
2017-09-14 10:01:15 +00:00
Jake Petroules
e3285ce85d Auto-detect CMake in standard paths on Windows and macOS
Change-Id: I8ae765eaed5bc234347e01fe81c208b77c1c32ec
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
Reviewed-by: Tobias Hunger <tobias.hunger@qt.io>
2017-06-23 17:41:13 +00:00
Tobias Hunger
5c5e5a3aae CMake: Remove "Prefer Ninja" checkbox on CMake Tool page
This is no longer needed now that the generator is a property of the
Kit.

Change-Id: Ife35fd9207c805a4ead1e067603df1bfc77e6855
Reviewed-by: Tim Jenssen <tim.jenssen@theqtcompany.com>
Reviewed-by: Tobias Hunger <tobias.hunger@theqtcompany.com>
2016-02-15 11:06:24 +00:00
Tobias Hunger
fa17e27b7f CMake: Delay initialization of CMakeTools
Do not run cmake 5 times during startup. Delay that as far as possible.

Also add a supportedGenerators() method while visiting the code anyway.

Fix up and simplify the other cmake help output parsers.

Change-Id: I6622d552ffe559bf099b4b278618676a045e350e
Reviewed-by: Tobias Hunger <tobias.hunger@theqtcompany.com>
2016-01-27 12:43:45 +00:00
Tobias Hunger
397e7f4843 Update License according to agreement with Free Qt Foundation
* Update files in src/plugins

Change-Id: Ia5d77fad7d19d4bb3498e78661982f68729adb22
Reviewed-by: Tobias Hunger <tobias.hunger@theqtcompany.com>
2016-01-19 15:57:01 +00:00
Tobias Hunger
b2b6d3c526 CMake: Semi-automatic cleanups
* Shorten header guards
* Use override and auto where possible
* Remove useless destructors, etc.
* Remove private slots sections, unify private: sections
* Use member initialization where it makes sense

Change-Id: I00eaf6d706adc16859176d1b68c631d3336bb39f
Reviewed-by: Tim Jenssen <tim.jenssen@theqtcompany.com>
2016-01-08 12:17:41 +00:00
Tobias Hunger
ca29cbfc8a Consistently use Utils::FileNameList
Consistently use Utils::FileNameList in favor of QList<Utils::FileName>

Change-Id: Iafbb466c882bfd91c25c9e78f107d401bfdb6d55
Reviewed-by: Niels Weber <niels.weber@theqtcompany.com>
2015-11-16 08:33:02 +00:00
Daniel Teske
ca8b43f6c8 Cmake: Fix autodetection of cmake on Windows
By using some of the infrastructure in Utils::Environment. Due to
wanting to find all cmake executables in PATH and not just the
first one, we need some custom code.

Change-Id: If3161d712b9f6e659450a3d0647f83344e68ba5d
Task-number: QTCREATORBUG-14740
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@theqtcompany.com>
Reviewed-by: Benjamin Zeller <benjamin.zeller@canonical.com>
Reviewed-by: Daniel Teske <daniel.teske@theqtcompany.com>
2015-07-17 10:25:25 +00:00
Daniel Teske
21d547998f Fix leaking of CMakeTools
Change-Id: I36d3d19cbd0bccc3ee74f8aae1622dbed22aa45a
Task-number: QTCREATORBUG-14727
Reviewed-by: Benjamin Zeller <benjamin.zeller@canonical.com>
Reviewed-by: Daniel Teske <daniel.teske@theqtcompany.com>
2015-07-15 14:56:04 +00:00
Benjamin Zeller
255b5850e2 CMakeProjectManager: Support mapping chroot include paths
Provide a way for plugins to map include paths into a build chroot.
Plugins can register a path mapper if required, otherwise the paths
are not touched.

Change-Id: I621982831fa354d6d0f558a6c1dce4e014421f12
Reviewed-by: Daniel Teske <daniel.teske@theqtcompany.com>
2015-04-21 09:58:53 +00:00
Eike Ziller
c8da2438ec CMakeSettings: Do not break most of other settings
Just do not return early, which then missed a settings->endGroup() call.
Fixes a regression introduced by
99e9643dea

Change-Id: I102eb76e3381012cddb73c1132b6443dd2cd592f
Task-number: QTCREATORBUG-14139
Task-number: QTCREATORBUG-14140
Reviewed-by: Daniel Teske <daniel.teske@theqtcompany.com>
2015-03-16 10:52:59 +00:00
Benjamin Zeller
bebcf69ce9 CMakeProjectManager: Provide way for plugins to autodetect cmake tools
This patch adds support for plugins to register a callback/lambda
to autodetect CMakeTools that would not be found by the default auto-
detection function. Without this feature the CMakeToolManager would
drop autodetected CMakeTools otherwise on every start.

Change-Id: I23b146e5b9acc60018ac87ea4b6cc7573fa0dd30
Reviewed-by: Daniel Teske <daniel.teske@theqtcompany.com>
2015-03-09 16:15:28 +00:00
Benjamin Zeller
1e2d266541 Make CMakeTool known to the Kits
This patch adds support for binding a specific CMakeTool to a Kit.
When creating a new Kit or loading a existing one without a valid
CMakeTool, the default CMakeTool will be set.

Change-Id: I28d0843a01c583c4b31fc680a0ec556b40cd9c0d
Reviewed-by: Daniel Teske <daniel.teske@theqtcompany.com>
2015-03-03 12:47:36 +00:00
Benjamin Zeller
99e9643dea Make it possible to register multiple cmake instances
This patch add the CMakeToolManager, a central repository for cmake instances.
One instance is always the currently used "default". By that its possible to
switch between different cmake installations. The next step will be adding
it to the Kits.

Change-Id: I310fdd805e0ed239077a5632303e891dbd1d9ea1
Reviewed-by: Leena Miettinen <riitta-leena.miettinen@theqtcompany.com>
Reviewed-by: Daniel Teske <daniel.teske@theqtcompany.com>
2015-02-24 09:54:43 +00:00