summaryrefslogtreecommitdiffstats
path: root/tools
Commit message (Collapse)AuthorAgeFilesLines
* Change license for tool filesLucie Gérard2024-04-042-2/+2
| | | | | | | | | | | According to QUIP-18 [1], all tool files should be LicenseRef-Qt-Commercial OR GPL-3.0-only WITH Qt-GPL-exception-1.0 [1]: https://contribute.qt-project.org/quips/18 Task-number: QTBUG-121787 Change-Id: I6a82a5e561fbb82413087340d198989c72a3e87a Reviewed-by: Kai Köhne <kai.koehne@qt.io>
* Update mocUlf Hermann2024-02-069-81/+116
| | | | | | | | | | The actual moc hasn't changed since 6.7 was branched off. We can pick the change back. Pick-to: 6.7 Fixes: QTBUG-121344 Change-Id: Ied2406ccfdd8307e8f142ff68e45a27786089cc1 Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
* Update the moc copyUlf Hermann2023-08-2212-302/+2518
| | | | | | | | | | | | We need to explicitly cast the string data to char now because we want to use the moc helper functions that expect char*. Previously we got away with unsigned char* by declaring the members ourselves. Since we always want to cast to char anyway when retrieving the data, it doesn't matter. Task-number: QTBUG-116255 Change-Id: I1ca017b5b434942606675514eddceb1f725a8bd7 Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
* Add the missing dependency on Scxml_sync_headers targetAlexey Edelev2023-06-011-0/+5
| | | | | | | | | | The qscxmlc tool uses source files from Scxml module. These source files use module include style that requires header files be in "sync". Add the explicit dependency on Scxml_sync_headers target to the qscxmlc tool. Change-Id: I561ee0e90f9483bbbaf50a140b50d5a2be068078 Reviewed-by: Alexandru Croitor <alexandru.croitor@qt.io>
* Update moc copy from qtbaseUlf Hermann2023-02-136-348/+370
| | | | | | | Pick-to: 6.5 Fixes: QTBUG-110352 Change-Id: I6ca9b1412d8206413a8ec1137413132e37bccaa9 Reviewed-by: Juha Vuolle <juha.vuolle@qt.io>
* Fix ecmascript model memory leak with qscxmlc generated statemachinesJuha Vuolle2023-02-041-3/+3
| | | | | | | | | | When models are set to statemachines with QScxmlStateMachine::setDataModel(), the state machine does not assume ownership of the model. Pick-to: 6.5 Change-Id: I18e69f8c34906719b7f729eab7d46d271cfdf950 Reviewed-by: Ulf Hermann <ulf.hermann@qt.io>
* Partially update moc copy from qtbaseMarc Mutz2023-01-031-1/+2
| | | | | | | | | | | | | | | This applies qtbase/b8c2a0c18a0676595946b5543ff88492a5fc7876 to the copy of the moc code used in qscxmlc. The moc copy here is severely out of sync with the qtbase version, so just running update_moc.sh produces a lot of conflicts, which is why I only applied this one patch. Created QTBUG-109556 to keep track of the rest. Fixes: QTBUG-109235 Pick-to: 6.5 6.4 6.2 5.15 Change-Id: I9e033453928110ac2aab1ecd6cde824c6abe0a97 Reviewed-by: Ulf Hermann <ulf.hermann@qt.io>
* Port from qAsConst() to std::as_const()Marc Mutz2022-10-073-5/+5
| | | | | | | | | | | | | | We've been requiring C++17 since Qt 6.0, and our qAsConst use finally starts to bother us (QTBUG-99313), so time to port away from it now. Since qAsConst has exactly the same semantics as std::as_const (down to rvalue treatment, constexpr'ness and noexcept'ness), there's really nothing more to it than a global search-and-replace. Task-number: QTBUG-99313 Change-Id: I4b4548c9d4a13337731159c1e1184e48bb0a328b Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
* Port from container::count() and length() to size()Marc Mutz2022-10-074-66/+66
| | | | | | | | | | | | | | | | | | | | | This is a semantic patch using ClangTidyTransformator as in qtbase/df9d882d41b741fef7c5beeddb0abe9d904443d8: auto QtContainerClass = anyOf( expr(hasType(cxxRecordDecl(isSameOrDerivedFrom(hasAnyName(classes))))).bind(o), expr(hasType(namedDecl(hasAnyName(<classes>)))).bind(o)); makeRule(cxxMemberCallExpr(on(QtContainerClass), callee(cxxMethodDecl(hasAnyName({"count", "length"), parameterCountIs(0))))), changeTo(cat(access(o, cat("size"), "()"))), cat("use 'size()' instead of 'count()/length()'")) a.k.a qt-port-to-std-compatible-api with config Scope: 'Container', with the extended set of container classes recognized. Change-Id: Iaf46b2ba54f3b125aee087c2cacb702d8d564201 Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org> Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
* Change the license of all CMakeLists.txt and *.cmake files to BSDLucie Gérard2022-08-232-2/+2
| | | | | | | Task-number: QTBUG-105718 Change-Id: I31c9b88ff5d23016fe8844d711553b010d9ba46e Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org> Reviewed-by: Jörg Bornemann <joerg.bornemann@qt.io>
* Add license headers to cmake filesLucie Gérard2022-07-072-0/+6
| | | | | | | | | | | | | CMakeLists.txt and .cmake files of significant size (more than 2 lines according to our check in tst_license.pl) now have the copyright and license header. Existing copyright statements remain intact Task-number: QTBUG-88621 Change-Id: I5d2588f7e3fd99bbb8bccca1dcb256afc215231b Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org> Reviewed-by: Jörg Bornemann <joerg.bornemann@qt.io>
* Use SPDX license identifiersLucie Gérard2022-06-1412-348/+26
| | | | | | | | | | | Replace the current license disclaimer in files by a SPDX-License-Identifier. License files are organized under LICENSES directory. Pick-to: 6.4 Task-number: QTBUG-67283 Change-Id: Ic435d3a484be01542f27431068419a2c252bd1f6 Reviewed-by: Jörg Bornemann <joerg.bornemann@qt.io>
* Remove unused .qrc filesJoerg Bornemann2022-01-181-7/+0
| | | | | | | Task-number: QTBUG-94446 Change-Id: I88f42eb731cbd9514f34a0e9e88b1ce90a4cf9e8 Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org> Reviewed-by: Ulf Hermann <ulf.hermann@qt.io>
* Move qscxmlc to libexecKai Köhne2021-10-271-0/+1
| | | | | | | | | | The compiler is usually not called manually, but through the build system. Task-number: QTBUG-88791 Change-Id: I5077b8110e2a840b2e97a922988bfa6f286a1a1f Reviewed-by: Ulf Hermann <ulf.hermann@qt.io> Reviewed-by: Joerg Bornemann <joerg.bornemann@qt.io>
* Skip unnecessary commands when cross-building toolsJoerg Bornemann2021-10-051-1/+1
| | | | | | | | | | Call qt_internal_return_unless_building_tools() directly after qt_internal_add_tool() to avoid having to special-case code for when this function only creates imported targets in cross-builds. Task-number: QTBUG-85084 Change-Id: I446c902ce6c66e722f9aa8b19aaec670bb065824 Reviewed-by: Alexandru Croitor <alexandru.croitor@qt.io>
* Rename qscxmlc CMake optionsJuha Vuolle2021-08-101-7/+10
| | | | | | | | | | | | | | | Renaming as a result of CMake API review. The old option names are still supported but marked as deprecated. [ChangeLog] Rename QSCXMLC_ARGUMENTS and OUTPUT_DIR CMake variables to be better aligned with other CMake APIs (OPTIONS and OUTPUT_DIRECTORY respectively). Pick-to: 6.2 Task-number: QTBUG-95178 Change-Id: I8500dd4e1d992ccba7378d37cda65d9760558dc5 Reviewed-by: Ulf Hermann <ulf.hermann@qt.io> Reviewed-by: Alexandru Croitor <alexandru.croitor@qt.io>
* Define repo target sets for the conan buildJoerg Bornemann2021-06-071-0/+2
| | | | | | | | Define the repo target sets qtscxml, qtscxmlqml, statemachine and statemachineqml. Change-Id: Id6ad659c942926e71027a108b9089d92bc5b2274 Reviewed-by: Alexandru Croitor <alexandru.croitor@qt.io>
* qt6_add_statecharts cmake macro documentationJuha Vuolle2021-04-191-2/+18
| | | | | | | | | | | | The aim is to include the macro to Qt6 cmake command reference. The commit also improves the macro's documentation which was a bit of a mix-and-match and not fully documented in the central location. Pick-to: 6.1 Task-number: QTBUG-82460 Change-Id: Ia9cfa50df5af9872779d015894e914a7d45bb8c1 Reviewed-by: Paul Wicking <paul.wicking@qt.io>
* Create a patch for synchronizing MOC with qtbaseJuha Vuolle2021-04-137-4/+637
| | | | | | | | | | | | | | | This commit adds a small script that can be used to both generate patch files and update the moc code from the upstream moc by applying these patches. The main purpose is to ease the synchronization work which has thus far been done manually. Pick-to: 6.1 Task-number: QTBUG-89830 Change-Id: I8c984b3ebcbefae2dfba4b4e887238f36b9c9c07 Reviewed-by: Edward Welbourne <edward.welbourne@qt.io> Reviewed-by: Alex Blasche <alexander.blasche@qt.io>
* Document manually generated (qscxmlc) source file usage with cmakeJuha Vuolle2021-03-161-0/+10
| | | | | | | | | | | With qmake this is taken care of by other means in the qscxmlc code template, but with cmake user needs to make an additional adjustment. Pick-to: 6.1 Task-number: QTBUG-89828 Change-Id: Ieb0d12ae1b46032671ac41360b01fd52eff189af Reviewed-by: Leena Miettinen <riitta-leena.miettinen@qt.io> Reviewed-by: Joerg Bornemann <joerg.bornemann@qt.io>
* Remove qtcxml repo qmake build support (examples excepted)Juha Vuolle2021-02-226-101/+0
| | | | | | | | | | | | | | | | | Remove qmake support by removing *.pr? files, with some exceptions: - Keep qmake support for the examples - Keeps qscxmlc.prf to retain STATECHARTS support for .pro files Also remove: - "#special case" and "# Generated from" comments from cmake files - .prev_CMakeLists.txt files Note: configure.json files are still kept as they still used to generate the configure.cmake Pick-to: 6.1 Task-number: QTBUG-89828 Change-Id: Ie9c7e86d099bbdc535f52b9f3e841fcf3973ca36 Reviewed-by: Joerg Bornemann <joerg.bornemann@qt.io>
* QtScxml: Move ecmascript data model to a pluginTamas Martinec2021-02-171-3/+6
| | | | | | | | | | Move qscxmlecmascriptdatamodel to a plugin to remove the build time qml dependency. Task-number: QTBUG-89831 Change-Id: Ibac93cfe39e35c084ed9811a113c88cc660c0436 Reviewed-by: Ulf Hermann <ulf.hermann@qt.io> Reviewed-by: Juha Vuolle <juha.vuolle@insta.fi>
* Qt6 related documentation changes for scxml moduleJuha Vuolle2021-02-111-10/+15
| | | | | | | | | | | | | | | | | | | Some perhaps less-obvious changes are: -Remove nonexistent imagedirs reference in qdocconf -Address some qdoc warnings (“/“ usage in an example and also std::function handling) -Fix ftpclient example filename references -Mark an escaped Q_OBJECT usage as badcode to suppress qdoc warning The Q_OBJECT itself cannot be unescaped as automoc will then fail. It shouldn't but that is the case. -Change the examples’ CMakeLists.txt to use single-line find_packages to ensure packages are not mixed and matched. Probability for problems is low but perhaps since these are examples that is appropriate Pick-to: 6.1 Task-number: QTBUG-89833 Change-Id: Ibf518aa71971e8e9d0af1b49c7de86fd28089e96 Reviewed-by: Paul Wicking <paul.wicking@qt.io>
* An attempt to fix --no-gui cmake CI build of the QtScxmlJuha Vuolle2021-01-281-0/+1
| | | | | | Task-number: QTBUG-89828 Change-Id: Ia3708141ec1e8d787055cd0bddb2280b8f4d81ff Reviewed-by: Joerg Bornemann <joerg.bornemann@qt.io>
* QtScxml module cmake portJuha Vuolle2021-01-212-10/+4
| | | | | | Task-number: QTBUG-89828 Change-Id: I95ec7905654bd3eaf61b22082ee1040aba4b9b24 Reviewed-by: Karsten Heimrich <karsten.heimrich@qt.io>
* Update the code generator from the upstream mocJuha Vuolle2021-01-212-369/+74
| | | | | | | | | | | | | | The generator nor the generated code did not compile with recent Qt6. With this commit the repository, including tests and examples, compile, and autotests pass. The main approach was: -Update the scxml::generator code from its upstream source qtbase::moc -Keep the changes marked with "-- QtScxml" tags -Minimize the 'diff' between qtbase::moc and qtscxml generator Task-number: QTBUG-89832 Change-Id: If544c587c797bc1118e145bd8161329a98ca6073 Reviewed-by: Ulf Hermann <ulf.hermann@qt.io> Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
* Fix a set of compilation errors against Qt6Juha Vuolle2021-01-212-2/+1
| | | | | | | | | | | | | | | | | | | | Fixes include -qmllistproperty uses qsizetype instead of int -implicit constructor calls that Qt6 marks as explicit -QEnableIf removed => std::enable_if -Replace the removed QCoreApplicationPrivate::cloneEvent() -Conflicting forward declaration for QStringList (comes via qglobal.h) N.B. after this task the generated (by generator.cpp) code won’t still compile, and it likely requires more in-depth study how to fix it => looks like they relate to the Qt6 property system changes. By temporarily disabling the violating generated code all unit tests pass though => needs a followup task to analyze and fix. Task-number: QTBUG-89832 Change-Id: I9f7d1cd5898b549f243a7df464ca124d29074c46 Reviewed-by: Ulf Hermann <ulf.hermann@qt.io> Reviewed-by: Karsten Heimrich <karsten.heimrich@qt.io>
* Re-generate all CMake filesJoerg Bornemann2021-01-192-5/+7
| | | | | Change-Id: I40dd28da4ba47bd15471b471138900cd22b4e409 Reviewed-by: Cristian Adam <cristian.adam@qt.io>
* Merge remote-tracking branch 'origin/wip/cmake' into devJoerg Bornemann2021-01-183-0/+110
|\ | | | | | | Change-Id: Id18b041d49c8ddebdb4aff404e438700d0441948
| * Regenerate projectswip/cmakeAlexandru Croitor2019-11-152-6/+4
| | | | | | | | | | | | Change-Id: I8f779c41390e242634e32ff94d13041a8559f272 Reviewed-by: Qt CMake Build Bot Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
| * Merge remote-tracking branch 'origin/dev' into wip/cmakeAlexandru Croitor2019-10-152-10/+10
| |\ | | | | | | | | | | | | | | | Removed dependencies.yaml. Change-Id: I7d1b06564b6b5c71882fe058f094894af7cb3efc
| | * Merge remote-tracking branch 'origin/wip/qt6' into devSimon Hausmann2019-10-042-29/+29
| | |\ | | | | | | | | | | | | | | | | | | | | | | | | Conflicts: .qmake.conf Change-Id: I1a52012a6e2c438a795222d687c33df6189962d2
| * | | Port QtScxml to CMakeJoerg Bornemann2019-09-263-0/+112
| | |/ | |/| | | | | | | | | | | | | Change-Id: I227f18b6a9825b6974eab6ba9feaf62bd0934133 Reviewed-by: Qt CMake Build Bot Reviewed-by: Alexandru Croitor <alexandru.croitor@qt.io>
| * | Bump Qt version to Qt 6Alexandru Croitor2019-07-102-29/+29
| | | | | | | | | | | | | | | | | | | | | | | | Also fix usages of text stream operators. Change-Id: I53cf87bb4bb055d56f2332d7737f205ec9560774 Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org> Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
* | | Adapt to latest qtbase changes, bump dependencyKarsten Heimrich2020-08-281-7/+7
| | | | | | | | | | | | | | | Change-Id: Ibe2af360f7fd63dbc541eaf1218935519886ef40 Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
* | | Adapt to latest qtbase MOC and QMetaType changesKarsten Heimrich2020-08-183-66/+229
| | | | | | | | | | | | | | | Change-Id: I0d6379b7739cd44b5e0668e4ec6b4de52ed7400c Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
* | | Fix broken build after introducing QByteArrayViewKarsten Heimrich2020-08-141-2/+4
| | | | | | | | | | | | | | | | | | | | | Ported from qtbase: 631127126cc14e7c01cc611532b3256b58785670 Change-Id: I33ecb4aca86a393e143f0773e6c3cf4e1e67938a Reviewed-by: Sona Kurazyan <sona.kurazyan@qt.io>
* | | Qt6: Port QtScxml to QStringViewKarsten Heimrich2020-07-011-8/+7
| | | | | | | | | | | | | | | | | | Task-number: QTBUG-84319 Change-Id: Ibb3af127a50adba9345540ea39c1c8cc17b72d06 Reviewed-by: Jarek Kobus <jaroslaw.kobus@qt.io>
* | | Update QtScxml module towards Qt6 changesKarsten Heimrich2020-07-016-425/+764
| | | | | | | | | | | | | | | | | | | | | | | | Fixes: QTBUG-85089 Change-Id: I78f8b1061f5dd75e435f9725fb6387670c1d2bf3 Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io> Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org> Reviewed-by: Ulf Hermann <ulf.hermann@qt.io>
* | | Use QList instead of QVectorJarek Kobus2020-06-263-12/+12
| | | | | | | | | | | | | | | | | | Task-number: QTBUG-84469 Change-Id: Ibaf2524e49e75ec660889261347eddbae9ccdbc6 Reviewed-by: Ulf Hermann <ulf.hermann@qt.io>
* | | Fix compilation after string data changes in qtbaseSimon Hausmann2020-01-243-16/+11
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Adjust the moc copied code to generate the same byte arrays for string literals and simplified the unicode string tables to just store offsets and size so that we can use QString::fromRawData (just like in qtdeclarative). Change-Id: Id19c165454451192e0764b5d889a1275e92417ac Reviewed-by: Ulf Hermann <ulf.hermann@qt.io>
* | | qscxmlc: Use QHash::insert(QHash)Liang Qi2019-12-161-2/+1
| | | | | | | | | | | | | | | | | | | | | | | | This amends a6d3c194fb0ea676d85dddf1fd005f169391666f. Task-number: QTBUG-80813 Change-Id: I8278f8cd35368386d83cef4c2e16a278570a0d31 Reviewed-by: Ulf Hermann <ulf.hermann@qt.io>
* | | qscxmlc: Avoid QHash::unite()Liang Qi2019-12-161-1/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | As we don't have QHash::insert(QHash), yet, we have to iterate for now. Task-number: QTBUG-80813 Change-Id: I2288a9d35362556a7cc869cfa7b0d51fb88a2c4e Reviewed-by: Paul Olav Tvete <paul.tvete@qt.io> Reviewed-by: Ulf Hermann <ulf.hermann@qt.io>
* | | Fix usages of text stream operatorsAlexandru Croitor2019-12-052-29/+29
| |/ |/| | | | | | | | | Change-Id: I53cf87bb4bb055d56f2332d7737f205ec9560774 (cherry picked from commit 38f88ebfebeccc1a6c2b41f885b2a6a8fa74a447) Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
* | Eradicate the last Q_FOREACHs and mark the module cleanMarc Mutz2019-07-181-8/+8
| | | | | | | | | | | | | | ... of Q_FOREACH, Java-style iterators, and QLinkedList use. Change-Id: Iec6c576e8c7aba81594e3d3e6c4d1e1cc487fbdf Reviewed-by: Volker Hilsheimer <volker.hilsheimer@qt.io>
* | Fix compilation with explicit QChar(*int*) ctorsMarc Mutz2019-07-151-2/+2
|/ | | | | | | | | | The QChar ctors from integral non-char types are under consideration for adding explicit. Fix users of these ctors ahead of the change. Change-Id: I3f3480336ba30a368034bb15b67ada854115e374 Reviewed-by: Volker Hilsheimer <volker.hilsheimer@qt.io>
* qscxmlc: Don't compress the templatesThiago Macieira2019-06-202-9/+6
| | | | | | | | | Those files are small, so we may as well not bother. Fixes: QTBUG-76521 Change-Id: Ief874765cd7b43798de3fffd15a9f511bc9c723a Reviewed-by: Simon Hausmann <simon.hausmann@qt.io> Reviewed-by: Ulf Hermann <ulf.hermann@qt.io>
* Use final keywordJarek Kobus2018-05-021-10/+10
| | | | | Change-Id: I727f6580a9060e1cab1a33cba0e42fdf9b34c739 Reviewed-by: Kai Koehne <kai.koehne@qt.io>
* Examples: Use override keywordJarek Kobus2018-05-021-10/+10
| | | | | Change-Id: I7191e2020e8c9ec4abe94e0ee5b730270fa66d13 Reviewed-by: Kai Koehne <kai.koehne@qt.io>
* Fix coding style issuesJarek Kobus2018-05-022-5/+5
| | | | | Change-Id: Ica7d960babffbf2ef1e6e43c032c236de4a3472e Reviewed-by: Kai Koehne <kai.koehne@qt.io>