aboutsummaryrefslogtreecommitdiffstats
path: root/src/app
Commit message (Collapse)AuthorAgeFilesLines
...
* Modernize variable declarationsDenis Shienkov2017-11-302-2/+2
| | | | | | | | Use 'const' and 'auto' keywords more where static_cast is used. Change-Id: I60152b90fe5e44aa1ca513b43f133e604ed6417f Reviewed-by: Jake Petroules <jake.petroules@qt.io> Reviewed-by: Denis Shienkov <denis.shienkov@gmail.com>
* Constrain Qt modules also to qbs.targetPlatformJake Petroules2017-11-291-46/+0
| | | | | | | | | | | This makes it possible to have multiple Qt versions for different platforms in the same module search path (much like multiple Android archs are present in the same module search path). This enables scenarios like building a Qt-based iOS and watchOS project in the same build configuration without messing with profiles. Change-Id: I448d7a768e8576373ff91d5283d46dbd7b8969ca Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
* Replace more loops with range-forJake Petroules2017-11-271-3/+1
| | | | | | | | ...or raw iterators for reverse iterations. Change-Id: I62a110ceeefaf70aaa41f6fb09d811f0eac05657 Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@qt.io> Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
* Replace 'foreach' macro with range-based 'for'Denis Shienkov2017-11-2411-69/+107
| | | | | Change-Id: I34479bc9673d0202363aeba5c7919efc8f0d7287 Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
* Add qbs.targetPlatform and qbs.hostPlatform propertiesJake Petroules2017-11-225-75/+59
| | | | | | | | | | | | | | | | | This allows users to set the target platform from within project files, since it is a scalar value. The values of qbs.targetOS and qbs.hostOS are now derived from these new scalar properties. [ChangeLog] Added qbs.targetPlatform and qbs.hostPlatform properties which are scalar versions of qbs.targetOS and qbs.hostOS. qbs.targetPlatform is a "write-only" property that can be used to set the OS/platform that is being targeted, while qbs.targetOS and qbs.hostOS should continue to be used to *read* the OS/platform that is being targeted. qbs.targetOS is also now read-only. Task-number: QBS-1070 Change-Id: Id3fd206a5b2ebee2d626f3e5ab02ecd1dc90d90a Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
* STL compatibility: use cbegin/cend() instead of constBegin/constEnd()Jake Petroules2017-11-221-2/+2
| | | | | Change-Id: I363e4d85e60c1c8ea1c0661d5088a7b8e1a5b806 Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
* STL compatibility: use push_back() instead of append()Jake Petroules2017-11-223-20/+16
| | | | | | | | | | ...or operator<< if the argument was itself a list, or brace init where appropriate. This is a simple find and replace with manual sanity check. Change-Id: I94b79cbf3752192dd258001bf1dfcd46f58ca352 Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
* Give the setupRunEnvironment script an additional parameterChristian Kandeler2017-11-228-4/+40
| | | | | | | | | | | Required by follow-up commit. [ChangeLog] The Module.setupRunEnvironment script now has a new parameter "config". Users can set it via the --setup-run-env-config option of the run command. Change-Id: I1be57fcff5321874cf3dcf4fb3a7ef7d6f69a8a5 Reviewed-by: Jake Petroules <jake.petroules@qt.io>
* Use nullptr to initialize the pointersDenis Shienkov2017-11-205-7/+7
| | | | | | Change-Id: I59d743f585410cb5c00d36a7b6f9a3e9d696d19e Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@qt.io> Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
* STL compatibility: use push_back() instead of operator<<Jake Petroules2017-11-167-23/+27
| | | | | | | ...and operator+= Change-Id: I848610544cacc2d187d601c0db567703c3e68c93 Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
* STL compatibility: use empty() instead of isEmpty()Jake Petroules2017-11-1616-60/+60
| | | | | | | This is a simple find and replace with manual sanity check. Change-Id: Iab6d46dcc3be246d1650aae2b1730f933b717be8 Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
* STL compatibility: use size() instead of count()Jake Petroules2017-11-1512-37/+37
| | | | | | | This is a simple find and replace with manual sanity check. Change-Id: Ia733befe7885dc3c643d5c84e151312bfd86a3c6 Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
* STL compatibility: use front() instead of first()Jake Petroules2017-11-1412-39/+39
| | | | | | | This is a simple find and replace with manual sanity check. Change-Id: I82f0eb38b6a5a3b75a4ed38d97bdb6ce164d09b3 Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
* Use "override" in command line parser classesChristian Kandeler2017-11-082-147/+147
| | | | | Change-Id: Ie76308a94dc3b6735cb64a032d2d077a52c17be2 Reviewed-by: Jake Petroules <jake.petroules@qt.io>
* CLI: Fix the --version optionChristian Kandeler2017-11-0710-45/+53
| | | | | | | | | | This option was supported in a very hacky way by attaching it to the "build" command, where it does not belong. Add a dedicated command instead and support the option variant in the same way as we do for --help. Change-Id: Ib8f1a0e44f9ae669093f059c86518138df510bc3 Reviewed-by: Joerg Bornemann <joerg.bornemann@qt.io>
* CLI: Make the --help option behave exactly like the help commandChristian Kandeler2017-11-071-5/+3
| | | | | | | For consistency, the option can also take an argument now. Change-Id: Iba585ef7ee007efe25d1ddc52f2375d164e51b9b Reviewed-by: Joerg Bornemann <joerg.bornemann@qt.io>
* CLI: Allow to mix options and property assignmentsChristian Kandeler2017-11-072-77/+68
| | | | | | | | | | | | | The strict separation we had before was annoying to users wanting to add options to a previous command line using the shell history, because the new option could not simply be appended if any property assignments were present. [ChangeLog] Command-line options do not have to precede property assignments anymore. Change-Id: I46fab716b2ff045adaf138db5194c3eba5b6818b Reviewed-by: Joerg Bornemann <joerg.bornemann@qt.io>
* Remove qbs-qmltypes appJake Petroules2017-11-025-95/+1
| | | | | | | | Now that we generate the qbs.qmltypes file during the build, it is no longer needed. Change-Id: I3180f55074b291d645abad65437d0cba4c80df25 Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
* CLI: Ensure non-applicable commands refuse to take property assignmentsChristian Kandeler2017-10-302-12/+5
| | | | | Change-Id: Ib339a2649ecf32670f2f65d0bf159dcc960214df Reviewed-by: Jake Petroules <jake.petroules@qt.io>
* Use the [[noreturn]] attribute instead of Q_NORETURNChristian Kandeler2017-10-305-9/+9
| | | | | | | We can do this now that we require MSVC 2015. Change-Id: I77be55435d4db6c6ff17afeff779e163cf3803fb Reviewed-by: Jake Petroules <jake.petroules@qt.io>
* CLI: Make the configuration name explicitChristian Kandeler2017-10-242-31/+33
| | | | | | | | | | | | | | | | | | | The old syntax took every non-option parameter not containing a colon as a configuration name, which was highly unintuitive. New users would always get it wrong, and experienced ones would still often encounter surprising behavior, in particular when forgetting to pass an option. For instance, this command: $ qbs build myproject.qbs # user forgot to specify the -f option would start building for a new configuration called 'myproject.qbs'. Instead, we now have a special key "config": $ qbs build config:debug [ChangeLog] Configuration names are now passed as "config:<name>" on the command line. Task-number: QBS-1158 Change-Id: I9b69a35de1f22b9b40efe6ca3616441b5f809aba Reviewed-by: Jake Petroules <jake.petroules@qt.io>
* Merge 1.10 into masterChristian Kandeler2017-10-203-17/+36
|\ | | | | | | Change-Id: I76e1f0c4a80fe1840311874e8ec63c8e17667473
| * CLI: Check generator name before buildingChristian Kandeler2017-10-182-20/+31
| | | | | | | | | | | | | | | | | | We can and should detect invalid generator names before starting a potentially expensive operation. Task-number: QBS-1194 Change-Id: I3588df48b7f3e3d7d085a2e4b620296f5eaf02c9 Reviewed-by: Jake Petroules <jake.petroules@qt.io>
| * setup-qt: Give feedback to the user if no Qt installations were detectedChristian Kandeler2017-10-171-0/+5
| | | | | | | | | | | | | | Task-number: QBS-1220 Change-Id: I8e99daf145c8255ca3233ca54cf9eb9d3cd84165 Reviewed-by: Jake Petroules <jake.petroules@qt.io> Reviewed-by: Alessandro Portale <alessandro.portale@qt.io>
| * Improve error messages for the generate commandJake Petroules2017-10-161-7/+10
| | | | | | | | | | Change-Id: Ifdd203c6bb1617916c79f7533fb52e9f2859d5e4 Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
* | Use Utilities.cStringQuote in qbs project filesChristian Kandeler2017-10-131-5/+5
|/ | | | | | | | This function has been available since 1.8. Change-Id: I0114bf8ec41f3be0c306be943d15599e09f69cc7 Reviewed-by: Joerg Bornemann <joerg.bornemann@qt.io> Reviewed-by: Jake Petroules <jake.petroules@qt.io>
* CLI: Ensure "restore only" mode for commands that don't support -fChristian Kandeler2017-10-055-5/+13
| | | | | | | This is now guaranteed programatically. Change-Id: Ifda974aa9347801ccf9e8b04f150cdf2368a756e Reviewed-by: Jake Petroules <jake.petroules@qt.io>
* Remove pointless option for update-timestamps commandChristian Kandeler2017-10-052-3/+3
| | | | | | | Also fix help output and CLI documentation. Change-Id: I45229809ea2f088628f1b512200fe3c8e99f4132 Reviewed-by: Joerg Bornemann <joerg.bornemann@qt.io>
* Improve dump-nodes-tree commandChristian Kandeler2017-10-051-6/+1
| | | | | | | | | | | | - Remove redundant output also for rule nodes (rather than just for artifacts). - Strip down the list of supported options. Some of the ones we listed there made no sense for this command. - Fix help output and CLI documentation. Change-Id: If13667d48e12de99df3bb19a4f82f97aa9256d02 Reviewed-by: Leena Miettinen <riitta-leena.miettinen@qt.io> Reviewed-by: Jake Petroules <jake.petroules@qt.io>
* Improve status commandChristian Kandeler2017-10-053-12/+6
| | | | | | | | | | - Indent also the untracked and missing file lists. - Remove pointless options. - Fix help output and CLI documentation. Change-Id: Iba23ad7fc3366cfac02b255b17cca9127556b9bb Reviewed-by: Leena Miettinen <riitta-leena.miettinen@qt.io> Reviewed-by: Jake Petroules <jake.petroules@qt.io>
* Fix shell commandChristian Kandeler2017-10-052-8/+10
| | | | | | | | | | | | | - Use the build environment rather than the system environment (that's the whole point of the command). - Remove the need for a specific product. - Use a more sensible prompt. - Strip down the list of supported options. - Fix typo in comment. Change-Id: I8e4040d44ab6a95e60a7265e05d5b66fb3dfa878 Reviewed-by: Joerg Bornemann <joerg.bornemann@qt.io> Reviewed-by: Leena Miettinen <riitta-leena.miettinen@qt.io>
* Fix help output for qbs-setup-androidChristian Kandeler2017-10-051-6/+4
| | | | | | | | | We forgot to update the help text when we got dropped the "one profile per architecture" approach. Change-Id: I81d7634e6228e4058d97031fc5bdf2a997f35429 Reviewed-by: Jake Petroules <jake.petroules@qt.io> Reviewed-by: Joerg Bornemann <joerg.bornemann@qt.io>
* Remove --jobs from the list of options for the resolve commandChristian Kandeler2017-10-051-1/+1
| | | | | | | | | This command does not spawn concurrent jobs. Change-Id: I4bc605b31ff94e463f1c65d98379843b50c36ec4 Reviewed-by: Jake Petroules <jake.petroules@qt.io> Reviewed-by: Leena Miettinen <riitta-leena.miettinen@qt.io> Reviewed-by: Joerg Bornemann <joerg.bornemann@qt.io>
* Fix bogus warning about missing objcopy in setup-toolchains on macOSJake Petroules2017-09-131-2/+13
| | | | | | Task-number: QBS-1192 Change-Id: I517b08100cea0154372b6b2fd7a9ac10778a7358 Reviewed-by: Joerg Bornemann <joerg.bornemann@qt.io>
* Remove the --force optionChristian Kandeler2017-09-047-39/+1
| | | | | | | | It hasn't been in use for a while now. Change-Id: I85c22d44309727ee458414cad0fb42c312030a9b Reviewed-by: Jake Petroules <jake.petroules@qt.io> Reviewed-by: Joerg Bornemann <joerg.bornemann@qt.io>
* Do not implicitly resolve a project as part of the "clean" commandChristian Kandeler2017-08-311-1/+3
| | | | | | | | | It makes no sense to call "clean" without a build graph, and neither do we need possible project files updates to be reflected in the build graph before running this operation. Change-Id: I986793e659e2ca1fdf7e58a52b787096527251ba Reviewed-by: Joerg Bornemann <joerg.bornemann@qt.io>
* Strip down the list of possible parameters for the "clean" commandChristian Kandeler2017-08-312-8/+25
| | | | | | | | | | | | | | | - We used to take the list of possible build options and selectively stripped away the ones that didn't apply, thus ending up with non-applicable build options as new ones were added. Instead, we now add the supported options explicitly. - Setting properties on a "qbs clean" command line makes no sense anymore now that this information is read from the build graph, so don't allow it. Change-Id: I30e18c3da4cc65ba263cccd9137d68fb111e01f5 Reviewed-by: Jake Petroules <jake.petroules@qt.io> Reviewed-by: Leena Miettinen <riitta-leena.miettinen@qt.io> Reviewed-by: Joerg Bornemann <joerg.bornemann@qt.io>
* Merge 1.9 into masterChristian Kandeler2017-08-284-0/+27
|\ | | | | | | Change-Id: I5320b7c62d6a80089df75c2caca79c15602c01e5
| * Add Windows UAC fix to qbs-setup-android and qbs-setup-toolchainsJake Petroules2017-08-214-0/+27
| | | | | | | | | | | | | | It was only applied to qbs-setup-qt, but missing from the others. Change-Id: I3f2dd63c717d9117a8699fc76bac93e573cad60c Reviewed-by: Joerg Bornemann <joerg.bornemann@qt.io>
* | Show short description in the general help outputChristian Kandeler2017-08-181-1/+1
| | | | | | | | | | | | | | ... of the command line tool. Change-Id: I9e28518d0b99036cdb7af0d04b94952a5278c9df Reviewed-by: Joerg Bornemann <joerg.bornemann@qt.io>
* | Make sure all files in the repository are shown in the Qbs project treeJake Petroules2017-08-161-1/+1
| | | | | | | | | | | | | | | | This is helpful when working with IDEs because it enables Find functions to work better, and avoids context switching to other editors. Change-Id: I419ab440bd2b43eaf712b2cc498cc6c2d6d9e21b Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
* | Merge 1.9 into masterChristian Kandeler2017-08-142-3/+5
|\| | | | | | | Change-Id: I6da76b0a53bf87105c4e7b48724d9760cb68e831
| * Fix help outputChristian Kandeler2017-08-081-1/+1
| | | | | | | | | | | | | | | | The term "Internal command" is ambiguous. Change-Id: I0d1c84bf813256ea9ac96582994e07106f36f4ea Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@qt.io> Reviewed-by: Jake Petroules <jake.petroules@qt.io>
| * Do not access the bundle module unconditionallyChristian Kandeler2017-08-021-2/+4
| | | | | | | | | | | | | | | | | | | | It is a mistake that the NativeBinary item currently pulls in the bundle module unconditionally (and also that the module is enabled everywhere). We want to change that. Prepare for the change by removing all unconditional accesses to the module's properties. Change-Id: If57b8222c1a0e2b09c33520882446fa71401f1f1 Reviewed-by: Joerg Bornemann <joerg.bornemann@qt.io>
* | Centralize conversion of multiplex id to human-readable stringChristian Kandeler2017-08-031-9/+2
| | | | | | | | | | | | | | | | | | | | | | ... and use it to construct a unique product display name that can be used in error messages and so on. [ChangeLog][API] Introduced ProductData::fullDisplayName() Change-Id: I9a35765d3694a8f24741f1506b00d499a1aa23a0 Reviewed-by: Joerg Bornemann <joerg.bornemann@qt.io> Reviewed-by: Jake Petroules <jake.petroules@qt.io>
* | Add initial support for Universal Windows PlatformJake Petroules2017-08-011-3/+1
| | | | | | | | | | | | | | | | | | | | | | [ChangeLog] Added initial support for the Universal Windows Platform (properties for which API families/partitions are available to code being compiled, and whether compiled binaries require an app container context to load/execute). Change-Id: Idd3e117bbb40bd547ae06c16318b2d2e38f07bb4 Reviewed-by: Maurice Kalinowski <maurice.kalinowski@qt.io> Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
* | Remove references to obsolete platformsJake Petroules2017-07-251-7/+0
| | | | | | | | | | | | | | | | | | We'll never support Windows CE, Windows Phone (8.x), or BlackBerry. Change-Id: I4adceb663098799f4a8e7283059add6ed9c15f1f Reviewed-by: Kai Koehne <kai.koehne@qt.io> Reviewed-by: Joerg Bornemann <joerg.bornemann@qt.io> Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@qt.io>
* | Merge 1.9 into masterChristian Kandeler2017-07-211-1/+2
|\| | | | | | | Change-Id: I4f4c626aecbbf7b3b4ceb3058133215b939ba674
| * Fix build with Qt < 5.8Christian Kandeler2017-07-171-0/+1
| | | | | | | | | | Change-Id: I27f6552baaab6e2eb7f146c4661b9c5e40c92e0b Reviewed-by: Joerg Bornemann <joerg.bornemann@qt.io>
| * Add fall-through annotations to switch statementsChristian Kandeler2017-07-171-1/+1
| | | | | | | | | | | | | | | | GCC 7 is warning against them as part of -Wextra. Change-Id: I00214bf09c0cb8ad2c881107d7d992edbe84437b Reviewed-by: Joerg Bornemann <joerg.bornemann@qt.io> Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>