aboutsummaryrefslogtreecommitdiffstats
path: root/src
Commit message (Collapse)AuthorAgeFilesLines
* Fix bug that causes re-linking on every build on Linux1.6Christian Kandeler2016-11-141-0/+2
| | | | | | | Introduced by d0516e8473. Change-Id: I5bf9e9acab9485ba47c4f5b02e7b0c4ae2493266 Reviewed-by: Joerg Bornemann <joerg.bornemann@qt.io>
* Executor: Fix dynamic rules with generated inputsv1.6.1Christian Kandeler2016-11-081-3/+9
| | | | | | | | | This has never worked, as the condition that was supposed to collect such inputs always evaluated to false. Task-number: QBS-1029 Change-Id: Idf3f86f12fa050a3d151f4551821bf4395f715d8 Reviewed-by: Joerg Bornemann <joerg.bornemann@qt.io>
* Executor: Only abort engine evaluation if engine is really evaluatingChristian Kandeler2016-11-081-1/+2
| | | | | | | Otherwise, crashes in QtScript have been observed. Change-Id: I5ef716ce6577f68d548b16ed682013fdc75e4005 Reviewed-by: Joerg Bornemann <joerg.bornemann@qt.io>
* Add missing qHash() function for QualifiedId classChristian Kandeler2016-10-311-0/+1
| | | | | Change-Id: Id616ca2a538b4ff7f6c88b129540966a866c50eb Reviewed-by: Joerg Bornemann <joerg.bornemann@qt.io>
* Fix module property assignments in Group itemsChristian Kandeler2016-10-3113-66/+383
| | | | | | | | | In particular, list properties were quite broken in the Group context. Task-number: QBS-1005 Task-number: QBS-1026 Change-Id: Id94fee42fdceb28f9a1ae541c293213095d6bb2c Reviewed-by: Joerg Bornemann <joerg.bornemann@qt.io>
* Fix the value of "original" for list propertiesChristian Kandeler2016-10-282-10/+13
| | | | | | | | It has to be the empty array in that case, as otherwise the value from the module prototype will get duplicated. Change-Id: I444342ce106fc6b9e302c0df18716906e926e966 Reviewed-by: Jake Petroules <jake.petroules@qt.io>
* Add module instance as scope to cloned module prototypeChristian Kandeler2016-10-243-4/+3
| | | | | | | | | | | | ... when evaluating the "prototype part" of list properties. This is necessary so that other properties appearing on the right-hand-side of the property use the value from the instance instead of the one from the prototype. Task-number: QBS-845 Task-number: QBS-966 Change-Id: I7b6c7d068e45f4805422c887239ec81b5c661880 Reviewed-by: Joerg Bornemann <joerg.bornemann@qt.io>
* Convert null variant values to empty listsChristian Kandeler2016-10-142-3/+14
| | | | | | | | ... if their declared type is a list. This is a workaround for QTBUG-51237. Change-Id: Ie9e02f5fd125ce73b993e59af0e3dc2b47fe14c1 Reviewed-by: Jake Petroules <jake.petroules@qt.io>
* Extend the autotest for module property assignments in GroupsChristian Kandeler2016-10-114-13/+94
| | | | | | | | So that we won't accidentally fix only one special case. Task-number: QBS-1005 Change-Id: I2093fd1569880f1ad683118cdd8df2576039f5f2 Reviewed-by: Jake Petroules <jake.petroules@qt.io>
* Cleanup remaining qbs_dummy files on detection of the MSVC environmentThomas Epting2016-10-061-0/+4
| | | | | | Task-number: QBS-1024 Change-Id: I2ec6b941d77bc769d119f30cac5b0f621db8930f Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
* Handle Q_NAMESPACEBogDan Vatra2016-09-283-2/+6
| | | | | | | Q_NAMESPACE will be introduced in Qt 5.8 which is used to add metafinfo to a namespace Change-Id: I16eacc488e9d9705305ced0847d3ad7bc8557292 Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
* Fix race conditionsChristian Kandeler2016-09-092-24/+19
| | | | | | | | Static variables must be initialized in a thread-safe way, because resolving for different profiles happens in parallel. Change-Id: I5d9b5e1233773e2e4371194df0501f4c2670396a Reviewed-by: Jake Petroules <jake.petroules@qt.io>
* Fix undefined behavior in command line parserChristian Kandeler2016-09-085-6/+5
| | | | | Change-Id: Ifa6b8b67f897d5405f7ec118ddf76831077ccfed Reviewed-by: Jake Petroules <jake.petroules@qt.io>
* Fix bug causing --wait-lock to fail if more than 10 tries are attemptedJake Petroules2016-09-061-1/+1
| | | | | | | This follows up 65cb4cba999b47a643e820a102b3185f861b97c1. Change-Id: I65d7dcf92f7bddc96ea71ed53d909b4dc9a675fe Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
* Handle ALL include path lists in the cpp dependency scannerJake Petroules2016-09-051-4/+14
| | | | | | | | | This will ensure that source files depending on header files within the search paths listed in systemIncludePaths and compilerIncludePaths will be recompiled when those headers change, as well. Change-Id: I6995fcd533b065505e3eec219294540579a73407 Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
* Remove assertions from command line parserChristian Kandeler2016-09-022-7/+0
| | | | | | | | They serve no useful purpose. Task-number: QBS-1015 Change-Id: I6e333250486e76033fe630d1d8cd0aad0aac74a0 Reviewed-by: Jake Petroules <jake.petroules@qt.io>
* setup-qt: Fix toolchain profile look-upChristian Kandeler2016-09-011-3/+1
| | | | | | | | Since commit 87a1478921, we no longer set qbs.architecture in the toolchain profile, but setup-qt still expected it. Change-Id: Id52c087cd91fa08768bf62a4f9d4850d676fe41a Reviewed-by: Kai Koehne <kai.koehne@qt.io>
* Do not use compiler include paths with moc from Qt 4.8Christian Kandeler2016-08-291-4/+9
| | | | | | | | | This moc is too old to parse certain header files correctly. Task-number: QBS-1004 Task-number: QTCREATORBUG-16798 Change-Id: Ic0c7787112d9ab5d334b62ea5c56014d6cd5892f Reviewed-by: Jake Petroules <jake.petroules@qt.io>
* Make sure a product's module properties are never nullChristian Kandeler2016-08-291-1/+1
| | | | | | | | That could happen when the product was force-disabled due to module loader errors (in IDE mode), leading to crashes later on. Change-Id: I7b3967cc238bb9e393af48a5ca599fcd410ed0b5 Reviewed-by: Jake Petroules <jake.petroules@qt.io>
* Fix file scope for Properties conditionsChristian Kandeler2016-08-291-1/+1
| | | | | | | | The file scope must correspond to the file where the Properties item is instantiated, because that's where the imports need to be looked up. Change-Id: Icfc0fd30bd43ee069ec7a4d2ea1a1e9b88560b2d Reviewed-by: Jake Petroules <jake.petroules@qt.io>
* More sensible fallback values for "base" & friendsChristian Kandeler2016-08-291-6/+12
| | | | | | | | | | | | | | When setting up the values of special properties like "base", "outer" and "original", we replaced invalid and undefined values with an empty array. This is all nice and well for array properties (so that people can write "base.concat()" without checking base first), but quite absurd for scalar properties. So for the latter, the only thing we do now is replace invalid values with undefined ones. The behavior for arrays stays the same. Change-Id: Icb3c74927c84025a07e3ef6c9c67b89d95320632 Reviewed-by: Jake Petroules <jake.petroules@qt.io> Reviewed-by: Joerg Bornemann <joerg.bornemann@qt.io>
* Do not allow "static" JS extension classes to be instantiatedChristian Kandeler2016-08-264-12/+4
| | | | | | | | | Apart from it being weird that people can instantiate them, it also makes us crash. Task-number: QBS-1009 Change-Id: Ic10ab530484df973b569aa5a185c06274ad2fef1 Reviewed-by: Jake Petroules <jake.petroules@qt.io>
* Make sure project.minimumQbsVersion is inherited to sub-projectsChristian Kandeler2016-08-261-1/+2
| | | | | Change-Id: I497df78263c970ef8f33557358cc65b7749eef09 Reviewed-by: Jake Petroules <jake.petroules@qt.io>
* Fix ProductData's equality operatorChristian Kandeler2016-08-231-0/+1
| | | | | Change-Id: Id73f8eaf285f030fb5164b72cf73dacdaccee437 Reviewed-by: Jake Petroules <jake.petroules@qt.io>
* Qt.core: Default to C++11 for version 5.7 and abovev1.6.0Christian Kandeler2016-08-191-0/+2
| | | | | | | | C++11 is required from Qt 5.7 on. Users shouldn't have to enable this manually in all their Qt-based products. Change-Id: I2cdbe393f62c9930cd74f129d0c14c109203425e Reviewed-by: Jake Petroules <jake.petroules@qt.io>
* Fix scoping issue for list propertiesChristian Kandeler2016-08-171-4/+8
| | | | | | | | | In the original fix for this issue (e34d268ba9), we forgot to take the "next" values into account. Task-number: QBS-955 Change-Id: Ie955af1b09250d6a3460aeb3ad45bc8b3292c90c Reviewed-by: Jake Petroules <jake.petroules@qt.io>
* Improve error message for installing multiple files to the same pathJake Petroules2016-08-171-1/+3
| | | | | | | This is frequently a result of omitting a qbs.installSourceBase binding. Change-Id: Ibd723f759967abac80914267ec8876a72997ea31 Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
* Fix warnings with custom properties in Export itemsChristian Kandeler2016-08-104-0/+27
| | | | | Change-Id: I6c6497827981868e6b2781ea4fe23309763aacb5 Reviewed-by: Jake Petroules <jake.petroules@qt.io>
* Add XFAILing autotest for newly discovered bugChristian Kandeler2016-08-104-0/+47
| | | | | | Task-number: QBS-1005 Change-Id: Id875b2c4656b9e264da77bb6e6b69168dc9493e4 Reviewed-by: Jake Petroules <jake.petroules@qt.io>
* Fix Probe cachingChristian Kandeler2016-08-052-6/+8
| | | | | | | | | We have to store a *list* of probe objects per code location. Otherwise, probes with different input properties will overwrite each other. Change-Id: Idde7f3f85b6b515bdbcc4b7cff985127cca508a2 Reviewed-by: Jake Petroules <jake.petroules@qt.io>
* Add a versionCompare function to the Utilities extensionJake Petroules2016-08-014-0/+57
| | | | | | | This will be used by a subsequent commit. Change-Id: Id7fe30a997e6ad4d09b78002376ecd7e16e1ad52 Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
* Fix change tracking for precompiled headersChristian Kandeler2016-08-011-1/+48
| | | | | | | | | | | | We used "explicitlyDependsOn" in the respective rules to make the pch sources depend on all header files. This was much too coarse, as it meant that the precompiled header was rebuilt whenever any header file in the product changed. Instead, we need to scan the pch sources just like all the other C and C++ source files to find out which header files they actually depend on. Change-Id: Iaec4ed85075b387d9f4b0fcd06b1e481851c6b10 Reviewed-by: Jake Petroules <jake.petroules@qt.io>
* Share probe results among products, if possibleChristian Kandeler2016-07-283-0/+17
| | | | | | | | | Most probes are not parameterized per product, meaning they only need to run once. Change-Id: Id1d08c3c552649a3f6147bb854b27b0315791942 Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@theqtcompany.com> Reviewed-by: Jake Petroules <jake.petroules@qt.io>
* Don't set the compiler or linker name in the Xcode probeJake Petroules2016-07-281-2/+0
| | | | | | | | | This fixes linkerMode:automatic where the linker is determined by Qbs, and the compilerName assignment is unnecessary because the default name is sufficient. Change-Id: I1fce60377f03313370e60df4ab0ed163ceae4655 Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
* Move item type check from ModuleLoader to ItemReaderASTVisitorChristian Kandeler2016-07-275-18/+15
| | | | | | | | That's more reliable, since we tweak some item types later on. Task-number: QBS-950 Change-Id: I85edbfa52c6b1da710d990e6b6c080052ad9b9cf Reviewed-by: Jake Petroules <jake.petroules@qt.io>
* Qt.core module: Add property for passing extra options to mocChristian Kandeler2016-07-272-0/+2
| | | | | | | | This is needed sometimes. Task-number: QBS-998 Change-Id: Idd15f79ec8996b4df5311425727e38ea8d6eebae Reviewed-by: Jake Petroules <jake.petroules@qt.io>
* Make sure all products get a valid locationChristian Kandeler2016-07-252-1/+4
| | | | | | | | | We omitted to set a location for products disabled due to errors, which lead to weird change tracking behavior, where a product's file path is checked for existence to determine if any files were removed. Change-Id: I82341081faa8129213e8fdeec30986ea09d2bb50 Reviewed-by: Jake Petroules <jake.petroules@qt.io>
* Introduce the --wait-lock command line optionJake Petroules2016-07-1413-9/+86
| | | | | | | | | | | | | This allows multiple qbs processes competing for the same configuration instance to be launched simultaneously, and the inactive instances will wait indefinitely for the lock file to be released. This is primarily intended for use by the IDE generator plugins like Visual Studio where the "Build Solution" command builds all projects in the solution in parallel (and this cannot be disabled). Change-Id: I13c37a21dd8386e3dfdab1f769b8242bfcfc2e45 Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
* Merge remote-tracking branch 'origin/1.5' into 1.6Orgad Shaneh2016-07-132-5/+8
|\ | | | | | | Change-Id: I62b6ae456af34ee07fde090cb583d2d9899cca98
| * BuildGraphLocker: Include 5.7.0 in versions that have QTBUG-533921.5Orgad Shaneh2016-07-131-2/+5
| | | | | | | | | | | | | | | | It was fixed following v5.6.1, but was not merged into 5.7.0, only 5.7.1 will contain the fix. Change-Id: Iaeb300a1b2eb93c4984ed39439903773736201f3 Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
| * FreeBSD fix: change order of includesRalf Nolden2016-07-081-3/+3
| | | | | | | | | | | | | | | | | | If <sys/user.h> is included before other system includes, compile errors for missing types appear on FreeBSD 9 and 11. Tested compiling on FreeBSD 9 and 11 with 1.5.2 packages in poudriere build jails. Change-Id: I3669a14c01fb8d11f14e103c008f6f9cb33f7307 Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
* | Allow to check for module versionChristian Kandeler2016-07-077-0/+72
| | | | | | | | | | | | | | | | | | | | | | | | | | Introduce a "version" property to the Module item and corresponding properties to the Depends item to set constraints on that version. [ChangeLog] Introduced the ability to check a module's version in a Depends item. Change-Id: I583b40216fb91af21f4e79ad403a7e327215ff79 Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@theqtcompany.com> Reviewed-by: Jake Petroules <jake.petroules@qt.io> Reviewed-by: Joerg Bornemann <joerg.bornemann@qt.io>
* | Try not to emit bogus errors after real errors in relaxed modeChristian Kandeler2016-07-073-10/+15
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | In "relaxed mode", intended for use by IDEs, we try to continue project resolving as much as we can even when errors are encountered. Since that mode was not present from the beginning, some code does not deal well with the resulting state. This patch takes the following measures: - Do not call handleProduct() if an error already occurred for that product. We will disable it later anyway, so there is no need to try merging modules, running probes etc. - Add the base module to the item's list of modules only after resolving explicit dependencies. This fixes an ugly "assert" message that would appear with bogus dependencies in Export items. While it was technically harmless, it had the potential to worry users. Change-Id: Ie650314b08488b975569678b931fd670bb8f43ac Reviewed-by: Joerg Bornemann <joerg.bornemann@qt.io>
* | Do not export QtXml from corelibJoerg Bornemann2016-07-063-5/+1
| | | | | | | | | | | | | | QtXml is only needed for building corelib. Change-Id: Idcbef666c09cd3aed4dc5353983001c0f57215d8 Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
* | Do not export QtScript from corelibJoerg Bornemann2016-07-063-3/+3
| | | | | | | | | | | | | | | | This was only needed, because libqtprofilesetup included scripttools.h which is no longer the case. Change-Id: I1966660fe3247a4b54783906c2fd139379cda119 Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
* | Extract toJSLiteral functions from scripttools.{h|cpp}Joerg Bornemann2016-07-0612-70/+154
| | | | | | | | | | | | | | | | | | The toJSLiteral functions do not use QtScript and are needed by libqtprofilesetup. This extraction is needed to remove the QtScript-dependency from libqtprofilesetup in a subsequent commit. Change-Id: Ide1737269d4b98f38eee93cdf9b6c33a6967c91c Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
* | Fix self-hosted build error on macOS with Qt 5.7Jake Petroules2016-07-061-0/+5
| | | | | | | | | | | | | | | | | | | | | | This was caused by a change in Qt 5.7 which #includes the Availability.h header which is not in moc's default search path. Qbs 1.6 contains a patch to supply moc with the correct header search paths, therefore this workaround is required until Qbs requires version 1.6 of itself for self hosted builds. Change-Id: I38db36235ac34a06a1a8e33fb474bb72b2928184 Reviewed-by: Joerg Bornemann <joerg.bornemann@qt.io>
* | Remove superfluous includeJoerg Bornemann2016-07-051-1/+0
| | | | | | | | | | Change-Id: Iec166e5d653d6acd970842dc46388a5aa62d5f42 Reviewed-by: Jake Petroules <jake.petroules@qt.io>
* | Remove superfluous includeJoerg Bornemann2016-07-011-1/+0
| | | | | | | | | | Change-Id: I91f4066ae81f515be27206fc11a35574e7a99bde Reviewed-by: Christian Kandeler <christian.kandeler@theqtcompany.com>
* | ModuleLoader: Add dependency cycle checkChristian Kandeler2016-06-304-0/+63
| | | | | | | | | | | | | | | | | | | | | | | | | | This is necessary, because otherwise we might silently skip some products, which can lead to unexpected results. There is no overhead in the normal code path, because the fact that we have a cycle can be detected for free by the product sorter. The check in the ProjectResolver is still needed, because wildcard dependencies are only resolved later. Added autotests to cover more cases. Change-Id: Ie3bf1db5bbb3eeb95d40f5139d294aac6ad840c1 Reviewed-by: Joerg Bornemann <joerg.bornemann@qt.io>