Commit Graph

27 Commits

Author SHA1 Message Date
hjk
430a33dcd9 Core/Utils: Migrate further to Utils::Id
The coreplugin/id.h header is kept for downstream for now.

Change-Id: I8c44590f7b988b3770ecdc177c40783e12353e66
Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
2020-07-06 06:07:13 +00:00
Tobias Hunger
01b0d4f8f5 CMake: Remove magic configuration from CMake
Get rid of magic configuration handling in the CMakeProjectManager.

* Use CMakeCache.txt as the sole source of truth, do not keep
  a shadow copy of configuration in the .user file
* Have initial CMake arguments that are easy to edit in batch
  (Fixes: QTCREATORBUG-18179) used whenever no CMakeCache.txt
  file is in the build directory. These allow for any thing that
  can be passed to CMake on the command line.
  (Fixes: QTCREATORBUG-16296)
* Ask when changes to CMake configuration were not applied
  (Fixes: QTCREATORBUG-18504)
* Run cmake with arguments effecting its configuration only when
  the CMake settings are changed in the UI, run CMake without any
  special arguments in all other cases.
* Get rid of the confusing dialog used to keep settings in sync between
  what is in CMakeCache.txt and Creator (Fixes: QTCREATORBUG-23218)

Change-Id: I26d55be7df733f084f5691ecf7d7b4352f58b8e7
Reviewed-by: Cristian Adam <cristian.adam@qt.io>
2020-06-09 16:34:00 +00:00
David Schulz
e3a0fe71e4 CMake: fixup env if jom is missing
Add the applitcation dir path to the path environment variable
if jom cannot be found there. This should fix the cannot find
jom error for binary releases since we ship jom with qc.

Fixes: QTCREATORBUG-22645
Change-Id: Ia3b55f794d3ac4b5fd6d2e85cf19f00bd8cddd2c
Reviewed-by: Tobias Hunger <tobias.hunger@qt.io>
2020-04-23 12:59:51 +00:00
Alessandro Portale
718af236de CMakeProjectManager: Export CMake*Aspect and CMakeConfigItem
Allow other plugins to set CMake specific Kit options.

Change-Id: I038e9fabc3d2cb8cc463adafebecd51b21ef3d05
Reviewed-by: Tobias Hunger <tobias.hunger@qt.io>
2019-09-26 15:06:41 +00:00
hjk
2b1c8aa877 ProjectExplorer: Introduce a alias for QList<Tasks>
Change-Id: I91391ad22b420926b0f512cac23cfe009048b218
Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
2019-05-28 05:51:40 +00:00
Christian Kandeler
d4565be655 ProjectExplorer: Drop KitAspect::defaultValue()
The functionality of this function overlapped with KitAspect::setup(),
leading to unclear responsibilities and resulting in bugs such as the
one fixed by 776d54e435.
Therefore, we drop the defaultValue() function, merging its
implementation with setup() where applicable.

Change-Id: Iefa9c3df8b76e97ddf9ad388516621f7ea6558d4
Reviewed-by: hjk <hjk@qt.io>
2019-03-15 14:47:18 +00:00
Christian Kandeler
ce19540b77 Move KitAspectWidget definitions alongside their KitAspects
A KitAspectWidget class is tightly coupled with the respective
KitAspect, and no one else ever needs to see any KitAspectWidget
subclass at build time.

Change-Id: I1883af3b054c225e1ff5dd913118715bfdbaacfc
Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
Reviewed-by: hjk <hjk@qt.io>
2019-02-11 14:39:29 +00:00
Christian Kandeler
83dd031960 ProjectExplorer: Rename KitInformation to KitAspect
The name "KitInformation" does not properly convey the fact that it
represents a certain *aspect* of a kit. The same goes for
"KitConfigWidget", which in addition was inconsistent with
"KitInformation".
We now use "KitAspect" and "KitAspectWidget".

Change-Id: I9804ee4cedc4d61fad533ea1dd4e4720e67fde97
Reviewed-by: hjk <hjk@qt.io>
2019-02-11 11:55:01 +00:00
Tobias Hunger
88b065db3f CMake: Do not crash when deleting cmake tools
Do not crash when the cmake tool that was used to parse the project
gets removed.

Change-Id: Ieda3ae2025dbcfb1f90d9bd01c5f0ed960756c6a
Reviewed-by: Ulf Hermann <ulf.hermann@qt.io>
2018-05-28 12:36:33 +00:00
Tobias Hunger
8b956868bb CMake: Register a feature for CMake-capable kits
This in theory enables to fix QTCREATORBUG-16204, but for that the wizard needs logic to adapt
the required features for the listed kits. That is still missing.

Task-number: QTCREATORBUG-16204
Change-Id: Ia01c11bb8c8567a9fc65b06912d6836b70a0195c
Reviewed-by: Tim Jenssen <tim.jenssen@qt.io>
2017-04-04 13:27:30 +00:00
Tobias Hunger
4f40d7778d CMake: Introduce project importer for cmake projects
Change-Id: Ie215e1c3f0286f6d98d10865e2b0a16b01391cd5
Reviewed-by: Tim Jenssen <tim.jenssen@qt.io>
2017-02-10 10:34:07 +00:00
Tobias Hunger
b3b6cfb5ef CMake: Improve generator selection in kits
Allow to select generator and extragenerator in a nicer way.
Enable support for platforms and toolsets.

Change-Id: I0c9aae635cdca0ec1db7f285e9cb2785172ed338
Reviewed-by: Tim Jenssen <tim.jenssen@qt.io>
Reviewed-by: Tobias Hunger <tobias.hunger@qt.io>
2016-09-30 07:27:14 +00:00
Tobias Hunger
e21df69354 CMake: Handle more information on the generator being used in a kit
Change-Id: I5834fdfa04b91beb7a61fa897209391c7fcf7d74
Reviewed-by: Tobias Hunger <tobias.hunger@qt.io>
2016-09-30 07:26:06 +00:00
Tobias Hunger
2431b7f4a2 CMake: Use final for KitInformation specializations
Change-Id: Ifb2f30f86d1ba1d6ee89db1660d74872c6dcf35c
Reviewed-by: Tobias Hunger <tobias.hunger@qt.io>
2016-09-27 12:45:49 +00:00
Eike Ziller
5c87432260 Merge remote-tracking branch 'origin/4.0'
Conflicts:
	src/plugins/qmldesigner/components/propertyeditor/propertyeditorqmlbackend.cpp

Change-Id: I6ae2d37290643d69390f679a54f7596782f3d97f
2016-04-12 11:34:46 +02:00
Tobias Hunger
58c326cb73 CMake: Add a reset button to the CMake Configuration edit in Kits
Add a reset button to the CMake configuration edit dialog that is
available in the kits configuration panel. It restores the default
value for the kit.

Change-Id: I89921e2c86cbf8d9658a32fe5fa51dc2f903ff00
Reviewed-by: Eike Ziller <eike.ziller@theqtcompany.com>
2016-04-08 10:10:56 +00:00
Tobias Hunger
79c710463e CMakeKitInformation: Expose cmake path to MacroExpander
Task-number: QTCREATORBUG-15367
Change-Id: Ia685b738c242b77eef2a96932dee1f7ebfe1787e
Reviewed-by: Tobias Hunger <tobias.hunger@theqtcompany.com>
2016-03-18 14:23:10 +00:00
Tobias Hunger
18afa34587 CMake: Add CMakeConfigurationKitInformation
Add CMakeConfigurationKitInformation and supporting classes.

This KitInformation can hold CMake settings that are to be applied
for all configurations when this kit is used. It contains e.g.
the Qt version and toolchain configured in the kit by default, but
can be extended to hold more.

The UI will warn if the toolchain or Qt version set up in CMake
does not match up with those used by the Kit, but it will allow
the user to proceed.

Change-Id: I73f06a6535ce14de323130d74af83b9cb2ec0f0f
Reviewed-by: Leena Miettinen <riitta-leena.miettinen@theqtcompany.com>
Reviewed-by: Tim Jenssen <tim.jenssen@theqtcompany.com>
2016-02-12 13:31:10 +00:00
Tobias Hunger
a764bb49d8 CMake: Add CMakeGeneratorKitInformation
Change-Id: I877c248c7b93268281fc68e814e479d24b844d5f
Reviewed-by: Tim Jenssen <tim.jenssen@theqtcompany.com>
2016-02-12 11:02:16 +00:00
Tobias Hunger
999a8d0516 CMake: Polish CMakeKitInformation
Change-Id: Ifc22c5ad41449ce6597b604746f25cab86662425
Reviewed-by: Tobias Hunger <tobias.hunger@theqtcompany.com>
2016-02-05 11:47:37 +00:00
Tobias Hunger
5404f9c480 CMake: Remove static defaultValue method from CMakeKitInformation
There is no need to expose this.

Change-Id: I164f1e787b742d330282125320b54a5b2ecb6134
Reviewed-by: Tobias Hunger <tobias.hunger@theqtcompany.com>
2016-02-05 11:47:23 +00:00
Tobias Hunger
eafb667066 KitInformation: Make defaultValue take a const Kit *
There is no reason not to.

Change-Id: I4accb0b690173d93ad6f4c9dd0bce66d8de75faa
Reviewed-by: Niels Weber <niels.weber@theqtcompany.com>
2016-02-05 11:35:20 +00:00
Tobias Hunger
cfa9dd4c03 CMake: Use pragma once consistently
Change-Id: Id164dea5e7047b87c3d11c53ebd044d567129e9c
Reviewed-by: Tobias Hunger <tobias.hunger@theqtcompany.com>
2016-01-27 09:15: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
51fec1a3ca cmakeprojectmanager: s/Q_DECL_OVERRIDE/override/g
Change-Id: I9465394a8c128e894e3e758d2494e5e8b50c8b37
Reviewed-by: Daniel Teske <daniel.teske@theqtcompany.com>
2015-06-03 13:48:24 +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