aboutsummaryrefslogtreecommitdiffstats
path: root/src/lib
Commit message (Collapse)AuthorAgeFilesLines
* Fix MSVC warningsOrgad Shaneh2019-09-132-2/+2
| | | | | | | | 'return': conversion from 'size_t' to 'int' Change-Id: I18e8fa03a9303855693da3027b722b104cee5d6d Reviewed-by: Richard Weickelt <richard@weickelt.de> Reviewed-by: hjk <hjk@qt.io>
* Process Command: Do not needlessly interpret output as textChristian Kandeler2019-08-261-1/+3
| | | | | | | | | ... when redirecting process output. Only do that if there is an output filter function. Otherwise, we break redirection of binary data. Fixes: QBS-1488 Change-Id: Ic5a1d2653fa8fc9c4f0eb5d31b7315d7aba3e030 Reviewed-by: Jörg Bornemann <joerg.bornemann@qt.io>
* Avoid uses of Java-style iteratorshjk2019-07-301-16/+4
| | | | | Change-Id: I90cece156033b5d223a86016401a2199f5b6c11e Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
* Prepare for explicit QChar constructorshjk2019-07-291-1/+1
| | | | | Change-Id: I906f63236230f10e6bdfb16ef3ee25cee8c407f6 Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
* Work around deprecation warnings in Qthjk2019-07-244-3/+19
| | | | | Change-Id: Iff45f56fc91f3d513440a3e2aaf519a7aa0f7744 Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
* Adapt to upstream introduction of std::hash<QString>hjk2019-07-011-0/+2
| | | | | Change-Id: If6671dd7c7a68ac3e1728fcb1790e6abf7c0b019 Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
* Add sanity check to socket launcherChristian Kandeler2019-06-281-0/+1
| | | | | | | | | | As far as I can see, this shouldn't happen, but let's prevent a crash at least in case it does. Task-number: QTCREATORBUG-22539 Change-Id: I4bd36364ca3f8bb8cdbe445e5b14037758b1e1fc Reviewed-by: Qbs CI Bot <travis-bot@weickelt.de> Reviewed-by: Mitch Curtis <mitch.curtis@qt.io>
* Respect QMAKE_LFLAGS set by the userDavide Pesavento2019-06-251-1/+1
| | | | | Change-Id: If0b411c734ddbb357843d6513a36a70d5c09a6fb Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
* Merge 1.13 into masterChristian Kandeler2019-06-141-1/+3
|\ | | | | | | Change-Id: Idab53d6bd9b6f2841e30d4a31f53ac53a05c2f09
| * Add Visual Studio 2019 support1.13Joerg Bornemann2019-06-071-1/+3
| | | | | | | | | | | | Fixes: QBS-1451 Change-Id: I644835cf8ce18d546e6c8e2c75f689766456555d Reviewed-by: Orgad Shaneh <orgads@gmail.com>
* | Avoid a Qt deprecation warninghjk2019-06-051-6/+5
| | | | | | | | | | Change-Id: I5b7a8927162821042ac0190fedac2ea14fc24223 Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
* | Fix some warnings about null pointersIvan Komissarov2019-06-044-4/+6
| | | | | | | | | | | | | | Some of them are false positives, some of them are possible bugs. Change-Id: Ic9c8a2970587e5152659b5b19f6b6d6df67e6809 Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
* | Merge "Merge 1.13 into master"The Qt Project2019-05-244-5/+17
|\ \
| * | Merge 1.13 into masterChristian Kandeler2019-05-234-5/+17
| |\| | | | | | | | | | Change-Id: Ic8e80604deb03e48fe264271de2e0add5023af87
| | * Fix module provider bug in IDE modeChristian Kandeler2019-05-233-3/+15
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | When re-resolving a project with an existing in-memory build graph, we must make sure that the old project object does not remove the generated modules from the build directory in its destructor. This fixes the following bug in Qt Creator: - Open a project initially (but do not build). - Edit the project file and re-resolve. - Build the project. This now fails, because the generated modules were erroneously removed in step 2. Change-Id: If6c1c1ed986e8f00e4d89ba5525bac7e032388d9 Reviewed-by: Jörg Bornemann <joerg.bornemann@qt.io>
| | * Transformer: Fix wrong variable nameOrgad Shaneh2019-05-211-2/+2
| | | | | | | | | | | | | | | | | | | | | | | | Amends commit f4f443a16a342300638d364175cf2958279cf23f. Change-Id: Ied9bd9188e719657228a53b7a7f1baca86c1bd71 Reviewed-by: Ivan Komissarov <ABBAPOH@gmail.com> Reviewed-by: Jörg Bornemann <joerg.bornemann@qt.io>
* | | Fix build errors when cross-building Qbs with MinGW on LinuxRichard Weickelt2019-05-243-3/+3
|/ / | | | | | | | | | | | | | | | | | | Linux file systems are case-sensitive while Windows file systems are usually not. That results in build errors when includes or libraries are incorrectly cased. Such errors wouldn't be noticed on Windows, but only when cross-building Qbs with MinGW on Linux. Change-Id: I3a340f907deaaf75b91369330d35918d70de56ca Reviewed-by: Jörg Bornemann <joerg.bornemann@qt.io>
* | Use std:: containers in ProjectBuildDataIvan Komissarov2019-05-226-26/+33
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | It appears, that destruction of complex QHashes/QLists took a bit time in refcounts. Optimize them by using std::unordered_map and std::vector instead. Plus, make structure simplier, instead of 2 hashes, use pair as a key. qbs::Internal::ProjectBuildData::~ProjectBuildData() Before: 11.00 ms 0.1% After: 6.00 ms 0.0% Change-Id: I82d8bec5a465210cfa54762088f47c606c0e48e5 Reviewed-by: Denis Shienkov <denis.shienkov@gmail.com> Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
* | Apply modernize-loop-convert fix-itIvan Komissarov2019-05-216-36/+28
| | | | | | | | | | | | | | Makes clang-tidy happier Change-Id: Ic29b552572719ea58c7ad385cc6e1d68cef9eedc Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
* | Apply modernize-use-auto fix-itIvan Komissarov2019-05-207-16/+16
| | | | | | | | | | | | | | | | Makes clang-tidy happier Change-Id: I75f3b6409b425b9a7054d7886ab0160a040b25d5 Reviewed-by: Denis Shienkov <denis.shienkov@gmail.com> Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
* | Fix -Wclazy-inefficient-qlist-softIvan Komissarov2019-05-202-2/+2
| | | | | | | | | | | | | | | | | | QLists were used with types that bigger than sizeof(void*) which lead to extra allocations Change-Id: Id716c6b4919f9a0ad62e1d2972319a600785afc5 Reviewed-by: Denis Shienkov <denis.shienkov@gmail.com> Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
* | Use std::unordered_map for m_storageIndiceshjk2019-05-201-6/+6
| | | | | | | | | | | | | | | | Makes the Ir event count go from ~8.28 billion to ~8.12 for a Qt Creator null build. Change-Id: I02714cd922fd9d42abe67e5115e3ffd64778f77a Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
* | Use std::vector in ItemPoolhjk2019-05-162-5/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Is: text data bss dec hex filename 11490 8 0 11498 2cea itempool.o Was: text data bss dec hex filename 12425 8 0 12433 3091 itempool.o-orig Also, less symbols. Change-Id: I6f90b126933f5fa6d00f5e1097faaa4276613a6a Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
* | Merge 1.13 into masterChristian Kandeler2019-05-102-2/+4
|\| | | | | | | Change-Id: Ic02d717f80f5d831f0cedb3b7c565a9bfef3a2a3
| * Fix qbsConfig test on MacosIvan Komissarov2019-05-022-2/+4
| | | | | | | | | | | | | | | | | | | | | | It seems, that QSettings is not working properly with SystemScope on Macos (QTBUG-21062). QSettings::fileName returns a path to a file in a test directory, not in "/Library/Application Support" as expected. Thus, canWriteToSystemSettings is true and test fails when real qbs binary tries to write to the /Library... location Change-Id: I726360a1daacf4871f944f5afe30089083283dce Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
* | Use = default in ProjectData and friendsIvan Komissarov2019-05-091-55/+15
| | | | | | | | | | | | Change-Id: Ic885bba12107b2a9f116dd8a33f1cad12ced1764 Reviewed-by: Denis Shienkov <denis.shienkov@gmail.com> Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
* | Use std::unique_ptr in PropertyMapIvan Komissarov2019-05-082-20/+9
| | | | | | | | | | | | | | | | This makes move ctors and destructor trivial Change-Id: Ifee00b7526fd1564fcf01f799230997f929b29db Reviewed-by: Denis Shienkov <denis.shienkov@gmail.com> Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
* | Add missing move ctors to ProjectData and friendsIvan Komissarov2019-05-062-1/+44
| | | | | | | | | | | | Change-Id: I6619817f8c87e9f643f7f1b6d2851799de439782 Reviewed-by: Denis Shienkov <denis.shienkov@gmail.com> Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
* | Add missing virtual destructorsIvan Komissarov2019-05-036-0/+7
| | | | | | | | | | Change-Id: I6a20f4475b52858f79c98b5ce3dd088aac7bc46e Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
* | Apply fix-its for the missing override keywordIvan Komissarov2019-05-0319-286/+286
| | | | | | | | | | | | | | | | Missing override is a warning in clang Change-Id: I90b899df37e690aebb942bffc65db54d9aa4050f Reviewed-by: Denis Shienkov <denis.shienkov@gmail.com> Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
* | Fix uninitialized variablesIvan Komissarov2019-05-0231-129/+107
| | | | | | | | | | | | | | | | | | This fixes most of clang analyzer warnings about uninitialized variables in ctors Change-Id: I879c785594307ed3fe7140588338a6b2a1e4db65 Reviewed-by: Denis Shienkov <denis.shienkov@gmail.com> Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
* | Merge 1.13 into masterChristian Kandeler2019-04-261-1/+1
|\| | | | | | | Change-Id: Ife9f7cd99dd5a531bcb670b2dfbd245471a8c379
| * Fix Windows build with QtScript-less Qt againDavid Schulz2019-04-251-1/+1
| | | | | | | | | | | | | | remove \r\n or \n from the qmake query output not just \r or \n Change-Id: I4cd12fb5e708b28eedc43381a8d67f9e54c82d9f Reviewed-by: Joerg Bornemann <joerg.bornemann@qt.io>
* | Fix tests on non-latin systemsIvan Komissarov2019-04-231-2/+2
| | | | | | | | | | | | | | | | Qt Creator uses non-latin letters in path to the build directory in case of ru_RU.UTF-8 $LANG on Linux. Now QBS does handle that correctly. Change-Id: Ifc727b120a5f0ee60972c5e3ed24067426db8df2 Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
* | Add support for the clang-cl compilerIvan Komissarov2019-04-106-31/+180
| | | | | | | | | | | | Task-number: QBS-1316 Change-Id: Ibf9da364610c260ead088a8990a70c7739d53c39 Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
* | Merge 1.13 into masterChristian Kandeler2019-03-186-16/+23
|\| | | | | | | Change-Id: I0678ef8cf6f81489914e79be903ca4d4c1cebada
| * Fix version detection for MSVC 2017David Schulz2019-03-152-2/+3
| | | | | | | | | | | | | | | | | | The version number for recent MSVC2017 installation has changed to the format \d+\.\d+\.\d+\.\d+ and the second number is not guaranteed to be a zero. Change-Id: I13728d2a5ea3162c3ff29558757cd576a83f4983 Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
| * Fix some warningshjk2019-03-044-14/+20
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | None of them really necessary or even desirable to fix, but... tools/launcherinterface.cpp:114:80: warning: ‘void QProcess::finished(int)’ is deprecated: Use QProcess::finished(int, QProcess::ExitStatus) instead [-Wdeprecated-declarations] api/projectdata.cpp: In function ‘QString qbs::mapToString(const QVariantMap&, const QString&)’: api/projectdata.cpp:882:15: warning: ‘void qSort(Container&) [with Container = QStringList]’ is deprecated: Use std::sort [-Wdeprecated-declarations] parser/qmljsparser.cpp: In member function ‘void QbsQmlJS::Parser::reallocateStack()’: parser/qmljsparser.cpp:72:104: warning: ‘void* realloc(void*, size_t)’ moving an object of non-trivially copyable type ‘class QStringRef’; use ‘new’ and ‘delete’ instead [-Wclass-memaccess] etc. The QStringRef is the only one theoretically applicable, but isn't in practice given the current implementation. Change-Id: Idb2a03e3fd096b6ad428615f81266f952d2a8d95 Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
* | Fix crashChristian Kandeler2019-03-111-1/+1
| | | | | | | | | | | | | | | | Don't move into reference. Amends 936eee744d. Change-Id: I7fa4e32f2d9f340f881cc746b74a752f81d34918 Reviewed-by: Ivan Komissarov <ABBAPOH@gmail.com> Reviewed-by: Joerg Bornemann <joerg.bornemann@qt.io>
* | Use pass-by-value and moveIvan Komissarov2019-03-0755-120/+136
| | | | | | | | | | | | | | This fixes -Wmodernize-pass-by-value Change-Id: I85a732867866e43c39c1d77937fbc645433c96bd Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
* | Fix calls to non-const begin()/end() in range-for loopsIvan Komissarov2019-03-0627-67/+118
|/ | | | | | | | This fixes -Wclazy-range-loop Change-Id: I08a435b700017cdbe27fbfdbda6e26840d9a3568 Reviewed-by: Christian Kandeler <christian.kandeler@qt.io> Reviewed-by: Denis Shienkov <denis.shienkov@gmail.com>
* Return initializer list where it is possibleDenis Shienkov2019-02-2652-183/+183
| | | | | | | | | This fixes this clang-tidy warning: warning: avoid repeating the return type from the declaration; use a braced initializer list instead [modernize-return-braced-init-list] Change-Id: I421e1e47462fe0e97788672684d47943af7df850 Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
* Fix build with Qt5.9 on macOSChristian Stenger2019-02-261-1/+1
| | | | | Change-Id: I1b02b1674794760ad973e04fad833e43e4190228 Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
* Use QStringLiteral more where it is possibleDenis Shienkov2019-02-2560-289/+290
| | | | | | Change-Id: I7419cc3fbc1e8776de3943852dcedab4c95d1c32 Reviewed-by: Anton Kudryavtsev <antkudr@mail.ru> Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
* Replace 'typedef' with 'using' where it is possibleDenis Shienkov2019-02-2325-86/+86
| | | | | | | | One exception is that the 'typedef' for function pointers were skipped due to an additional work is required. Change-Id: I2112fded3abeaee1d1f49f56adfd2914d5db0324 Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
* Use 'const auto' keywords more at objects allocationsDenis Shienkov2019-02-2312-171/+171
| | | | | | Change-Id: I592d433e7c473ae9f27ca08e701516efe53650ba Reviewed-by: Ivan Komissarov <ABBAPOH@gmail.com> Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
* Add const-references for non trivial types in range-for loopsIvan Komissarov2019-02-202-5/+5
| | | | | | | This fixes -Wclazy-range-loop Change-Id: I5424d2626d6134ac7be2ce70b83f5a617f58dd7e Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
* Options: Add missed move-ctorsIvan Komissarov2019-02-204-0/+12
| | | | | | Change-Id: I040e90bebe51e587e21b5db3292790a1b2f172f7 Reviewed-by: Denis Shienkov <denis.shienkov@gmail.com> Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
* Remove usages of deprecated QString::nullOrgad Shaneh2019-02-191-3/+3
| | | | | Change-Id: If126c3b27272386ed513fdfdbf9448ec00019c11 Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
* Set the default platform toolset for VS 2019 to v142Joerg Bornemann2019-02-121-3/+8
| | | | | Change-Id: I1fb773d9aaa527f4bead263626c604a47d9f4568 Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>