summaryrefslogtreecommitdiff
path: root/doc/src/cmake
Commit message (Collapse)AuthorAgeFilesLines
* Fix a broken link to qt_cmake_policiesAmir Masoud Abdol2023-02-281-0/+1
| | | | | | Pick-to: 6.5 Change-Id: I99a6071a4314c92e94b52568cc26f9b898077f6d Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
* Update Building a QML application for 6.5Fabian Kosmale2023-02-242-19/+20
| | | | | | | | | | | | | | | | - se qt_standard_project_setup instead of AUTOMOC - pass REQUIRED 6.5 to it - adjust the resource path URL accordingly - Group all content describing the effect of qt_add_qml_module together As a drive-by, also pass REQUIRED 6.5 to qt_standard_project_setup in the "Reusable QML module" section. Task-number: QTBUG-109799 Pick-to: 6.5 Change-Id: Ia10b0d9a3010d8653f15b626fb1828ebafade186 Reviewed-by: Leena Miettinen <riitta-leena.miettinen@qt.io> Reviewed-by: Ulf Hermann <ulf.hermann@qt.io>
* Add qt_add_grpc cmake procedure to the documented listTatiana Borisova2023-02-232-0/+7
| | | | | | | Pick-to: 6.5 Change-Id: If04c6c6e763604e6486f67b2a4ca0d70902eafa7 Reviewed-by: Konrad Kujawa <konrad.kujawa@qt.io> Reviewed-by: Alexey Edelev <alexey.edelev@qt.io>
* Doc: Fix included snippets for CMake manualKai Köhne2023-02-109-89/+95
| | | | | | | | | | | | | Commit 37540e46f added license headers to most .make files. This resulted in the license headers to show up also in the documentation, and also confused the logic to show only parts of it. Fix this by inlining most sources, or skipping past the copyright lines. Pick-to: 6.5 Change-Id: I1351697114532f25f271f5f4c61e740d3c928832 Reviewed-by: Leena Miettinen <riitta-leena.miettinen@qt.io>
* Add the Qt CMake Policies to cmake-manualAmir Masoud Abdol2023-01-301-2/+21
| | | | | | | Pick-to: 6.5 Task-number: QTBUG-96233 Change-Id: Ia8ec96c0b140b8461ab8f2bb5a004f5296f844c6 Reviewed-by: Leena Miettinen <riitta-leena.miettinen@qt.io>
* Add toplevel CMake file for "Building re-usable QML modules"Ulf Hermann2023-01-262-2/+21
| | | | | | | | Pick-to: 6.5 Fixes: QTBUG-105362 Change-Id: I174830599353869119dc7de46e8667bcd37978fd Reviewed-by: Sami Shalayel <sami.shalayel@qt.io> Reviewed-by: Mitch Curtis <mitch.curtis@qt.io>
* CMake: Add qtshadertools docs to cmake command referenceAlexandru Croitor2022-12-152-0/+6
| | | | | | Pick-to: 6.4 6.5 Change-Id: I0387aea9133e18ad3695226d76e1a35f1d2f6848 Reviewed-by: Laszlo Agocs <laszlo.agocs@qt.io>
* CMake: Add qtprotobuf docs to cmake command referenceAlexandru Croitor2022-12-052-0/+7
| | | | | Change-Id: Iec7a4054c020b85510d86ad863d65dcbc9a5153d Reviewed-by: Alexey Edelev <alexey.edelev@qt.io>
* CMake: Adapt command namesKai Köhne2022-11-031-6/+6
| | | | | | | | | Follow-up change to the respective changes in qttools, qtinterfaceframework. Pick-to: 6.2 6.4 6.4.1 Change-Id: I3c737399aefb78a568e287e1685100359d80e1f5 Reviewed-by: Paul Wicking <paul.wicking@qt.io>
* Doc: CMake Manual: Fix QtIntefraceFramework command annotationDominik Holland2022-10-181-2/+1
| | | | | | | | | Also add a link to it in the Table of Contents Fixes: QTBUG-105220 Pick-to: 6.2 6.3 6.4 Change-Id: I7e28760549188c4abdcf5891b4e8ca8a7d5255b2 Reviewed-by: Topi Reiniö <topi.reinio@qt.io>
* Doc: CMake Manual: List commands from QtInterfaceframeworkDominik Holland2022-09-072-1/+13
| | | | | | | Fixes: QTBUG-105220 Pick-to: 6.2 6.3 6.4 6.4.0 Change-Id: I593648cde89a5dd7fc127bd56a28cbf7826eeb34 Reviewed-by: Topi Reiniö <topi.reinio@qt.io>
* Doc: List the global CMake properties of QtCore and QtQmlJoerg Bornemann2022-09-011-0/+8
| | | | | | Task-number: QTBUG-99808 Change-Id: Ie727031c99a86774492136e61c1af42e28b5e8d8 Reviewed-by: Alexandru Croitor <alexandru.croitor@qt.io>
* Change the license of all CMakeLists.txt and *.cmake files to BSDLucie Gérard2022-08-2312-12/+12
| | | | | | | Task-number: QTBUG-105718 Change-Id: Iec124e0bceb4335370674a222970cd9c1b90763f 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-0712-0/+36
| | | | | | | | | | | | 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: I9499ba4c20f610ffe8af0fc3e29e6581247f2c40 Reviewed-by: Jörg Bornemann <joerg.bornemann@qt.io>
* Fix cmake example to be consistent about Qt modulesKai Köhne2022-06-101-1/+1
| | | | | | | Pick-to: 6.2 6.3 6.4 Change-Id: I1a7fb4745d7feac4213d2ca555d1d635ec1d615d Reviewed-by: Laszlo Papp <lpapp@kde.org> Reviewed-by: Volker Hilsheimer <volker.hilsheimer@qt.io>
* Add the missing endif() to a cmake exampleLaszlo Papp2022-06-091-0/+1
| | | | | | Pick-to: 6.4 6.3 6.2 Change-Id: I2a28256c1735506a57d77960683b5f808e653ee0 Reviewed-by: Volker Hilsheimer <volker.hilsheimer@qt.io>
* Use SPDX license identifiersLucie Gérard2022-06-071-27/+3
| | | | | | | | | | | | 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: Idfd176b7f7b077a5b7c66b7738dc9bcac94ab290 Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org> Reviewed-by: Jörg Bornemann <joerg.bornemann@qt.io>
* Doc: Link "Getting started" and "Build projects" CMake pagesJoerg Bornemann2022-05-171-0/+8
| | | | | | | | Add paragraphs that explain each page's purpose and link to the other. Pick-to: 6.2 6.3 Change-Id: I44697ede0257bf8a57aacaa24b762dc354966a25 Reviewed-by: Alexandru Croitor <alexandru.croitor@qt.io>
* Doc: Mention qt_add_library on the Getting started with CMake pageJoerg Bornemann2022-05-171-0/+2
| | | | | | | | We only mentioned qt_add_executable so far. Pick-to: 6.2 6.3 Change-Id: Icdf4a3b22ffc74ca157c0ad4e3330d673ca9adda Reviewed-by: Alexandru Croitor <alexandru.croitor@qt.io>
* Fix qdoc warnings about missing links in qtcmakeKai Köhne2022-04-071-8/+9
| | | | | | | | | | | | Add qtquick as dependency, to fix qt5/qtdoc/doc/src/cmake/cmake-manual.qdoc:459: (qdoc) warning: Can't link to 'Qt Quick' Also take the opportunity to sort the lines. Pick-to: 6.3 Change-Id: Id013f9875db781467d131848eba9c646516f4bfb Reviewed-by: Venugopal Shivashankar <Venugopal.Shivashankar@qt.io>
* Fix naming of QML runtime toolKai Köhne2022-04-061-3/+3
| | | | | | | | | Give the page an explicit target, and use consistent naming: qml is the executable, QML Runtime Tool the name. Pick-to: 6.3 Change-Id: I39eab8710b86067e87e2ad7bd3d6540094666290 Reviewed-by: Venugopal Shivashankar <Venugopal.Shivashankar@qt.io>
* CMake: Add building QML applications and modulesJaishree Vyas2022-03-223-3/+187
| | | | | | | | | | Based on the existing blog post Fixes: QTBUG-100450 Pick-to: 6.2 6.3 6.3.0 Change-Id: I7dc6507e8cc219b72ab029e8f57d662d849bba96 Reviewed-by: Leena Miettinen <riitta-leena.miettinen@qt.io> Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
* CMake: Document source file propertiesAlexandru Croitor2022-02-161-0/+20
| | | | | | | | | Pick-to: 6.2 6.3 Task-number: QTBUG-100224 Change-Id: Ie7479ec87bef33db95f1088cd32ee762a2f99960 Reviewed-by: Alexey Edelev <alexey.edelev@qt.io> Reviewed-by: Jörg Bornemann <joerg.bornemann@qt.io> Reviewed-by: Leena Miettinen <riitta-leena.miettinen@qt.io>
* Doc: Use qt_standard_project_setup() in our CMake snippetsJoerg Bornemann2022-02-154-23/+24
| | | | | | | | | | ...on the "Getting started with CMake" page. Pick-to: 6.3 Fixes: QTBUG-100793 Task-number: QTBUG-100209 Change-Id: I8e7d820014b57ab725961d6aa24ba08da4cdb95d Reviewed-by: Alexandru Croitor <alexandru.croitor@qt.io>
* Doc: CMake Manual: List commands from QtWebEngineCoreTopi Reinio2022-02-141-0/+6
| | | | | | | | | | | Adds the newly-introduced qt_add_webengine_dictionary command to the landing page and command reference. Pick-to: 6.3 Task-number: QTBUG-100210 Change-Id: I2f452d4e53f7949f8780b2556374cf445722ba15 Reviewed-by: Alexandru Croitor <alexandru.croitor@qt.io> Reviewed-by: Kai Koehne <kai.koehne@qt.io>
* Include WebEngine API in qtcmakeKai Köhne2022-01-281-1/+2
| | | | | | | | | qtwebengine now features a qt_add_webengine_dictionary(). Let's make sure it shows up in the overview documentation. Pick-to: 6.3 Change-Id: I2c533b12a311ef27b602d53450bb6cd9a7ed554f Reviewed-by: Michal Klocek <michal.klocek@qt.io>
* Doc: Add a "Building projects on the command line" pageJoerg Bornemann2022-01-261-2/+121
| | | | | | | | | ...to the CMake manual. Pick-to: 6.3 Task-number: QTBUG-84789 Change-Id: I6b5ee322e84f097082542ccb7443d7f22b60be73 Reviewed-by: Venugopal Shivashankar <Venugopal.Shivashankar@qt.io>
* Doc: Add "Adding translations" sectionJoerg Bornemann2022-01-252-0/+44
| | | | | | | | | | | | | | ...under "Getting started with CMake". Describe the most common use case and refer to the reference for details. Pick-to: 6.3 Task-number: QTBUG-84789 Change-Id: I8c42c9bb66632daf402a575bb2d2e23f51d5b721 Reviewed-by: Leena Miettinen <riitta-leena.miettinen@qt.io> Reviewed-by: Alexey Edelev <alexey.edelev@qt.io> Reviewed-by: Alexandru Croitor <alexandru.croitor@qt.io>
* Doc: Unify "CMake Documentation" linksJoerg Bornemann2022-01-131-2/+2
| | | | | | | | | This external page is defined in qtbase. We can just use \l{CMake Documentation} everywhere. Pick-to: 6.3 Change-Id: I71a72260f93d1b9c4d8a970e261ecfd116e98348 Reviewed-by: Leena Miettinen <riitta-leena.miettinen@qt.io>
* Doc: Mention the official CMake tutorialJoerg Bornemann2022-01-131-0/+2
| | | | | | | | Pick-to: 6.3 Change-Id: I1a4a955930691715bc19312b8888a67b6ee8aaaf Reviewed-by: Kai Koehne <kai.koehne@qt.io> Reviewed-by: Alexey Edelev <alexey.edelev@qt.io> Reviewed-by: Leena Miettinen <riitta-leena.miettinen@qt.io>
* Doc: Describe how to build and use libraries with CMakeJoerg Bornemann2022-01-136-0/+163
| | | | | | | | | | | | ...on the "Getting started with CMake" page. Also, because we extend upon it, describe how to structure a complex project. Pick-to: 6.3 Task-number: QTBUG-84789 Change-Id: I473ae1b8ae80eb13825dabc745c951d9a7f448fb Reviewed-by: Kai Koehne <kai.koehne@qt.io>
* Doc: Add "Adding resources section"Joerg Bornemann2022-01-132-0/+24
| | | | | | | | | | | ...under "Getting started with CMake". Recommend the qt_add_resources command like proposed in QTBUG-87643. Pick-to: 6.3 Task-number: QTBUG-84789 Change-Id: I8cd551107c8cdd24042e344120ed0d313b5d9ac1 Reviewed-by: Alexey Edelev <alexey.edelev@qt.io>
* Doc: Add "Building a C++ console application" sectionJoerg Bornemann2022-01-123-24/+92
| | | | | | | | | | | | | | | | | ...on the "Getting started with CMake" page. Split "Build a C++ GUI application" into a "Building a C++ console application" and, based on that, "Building a C++ GUI application". Remove the mention of CMAKE_AUTORCC, because we want to discourage its use. See QTBUG-87643. In a subsequent commit, we will add a guide how to use resources. Pick-to: 6.3 Task-number: QTBUG-84789 Change-Id: I9434c88538af0d6e7c5e2c86ee86c3d697d7a576 Reviewed-by: Leena Miettinen <riitta-leena.miettinen@qt.io> Reviewed-by: Kai Koehne <kai.koehne@qt.io>
* Use simpler names for documentation targetsKai Köhne2022-01-121-2/+2
| | | | | | | | | | | | | | Name the build targets like the project, without a 'doc' attached. This way, you can now e.g. run ninja html_docs_qtcmake instead of ninja html_docs_CMakeDoc Change-Id: I817e8ad91e8646c17cc7b7ffad70fa2b415668f4 Reviewed-by: Joerg Bornemann <joerg.bornemann@qt.io>
* Doc: Move "CMake Command Reference" upJoerg Bornemann2022-01-061-14/+14
| | | | | | | | | ...before the variable and property reference, because this is more relevant. Pick-to: 6.3 Change-Id: I4d30ba3dea48e146fcd493b9faba7576e6065c8c Reviewed-by: Leena Miettinen <riitta-leena.miettinen@qt.io>
* Doc: Use find_package(Qt6 REQUIRED COMPONENTS ...) idiomKai Köhne2021-12-173-5/+5
| | | | | | | | | | Using REQUIRED as a prefix instead of suffix works better with OPTIONAL_COMPONENTS, and is also the order in the CMake manual. Task-number: QTBUG-98867 Pick-to: 6.2 6.3 Change-Id: I7ba13e267f96bb9553814651f1f6c3c3f270967e Reviewed-by: Alexandru Croitor <alexandru.croitor@qt.io>
* Doc: Enable zero warning limitVenugopal Shivashankar2021-11-151-0/+4
| | | | | Change-Id: I157ef93d8a5c07528de267fe51ea9ed7f161a7ee Reviewed-by: Paul Wicking <paul.wicking@qt.io>
* Doc: Fix references to cmake-commands-qtcoreKai Köhne2021-10-061-3/+3
| | | | | | | | The group got renamed in qtbase. Pick-to: 6.2 Change-Id: I8853267ed90feb39895ce047437e56967ef87c6f Reviewed-by: Paul Wicking <paul.wicking@qt.io>
* Mention qt_add_executable() in the CMake getting started manualCraig Scott2021-09-241-0/+6
| | | | | | | Fixes: QTBUG-95712 Pick-to: 6.2 6.2.0 Change-Id: I74b75b12b31d288359c29ec9f205ac044f8889b2 Reviewed-by: Alexandru Croitor <alexandru.croitor@qt.io>
* Doc: Use only major.minor versions in hello world CMakeKai Köhne2021-09-221-1/+1
| | | | | | | | | | | | Specifying the patch level version is not so common. It also exposes an issue with the qdoc highlighting, where the second dot is not colored like the rest: https://doc.qt.io/qt-6/cmake-get-started.html Qt Creator wizards also only use major.minor version. Pick-to: 6.2 Change-Id: I068fd94de3cdc3ec6ef21958e5416047b8391ad7 Reviewed-by: Craig Scott <craig.scott@qt.io>
* Update the docs now that qt_disable_unicode_defines() is documentedCraig Scott2021-09-221-2/+2
| | | | | | | | Task-number: QTBUG-95712 Pick-to: 6.2 6.2.0 Change-Id: If014345d7723de7e4a31ee41a0fb5366deafda0d Reviewed-by: Alexandru Croitor <alexandru.croitor@qt.io> Reviewed-by: Topi Reiniö <topi.reinio@qt.io>
* Doc: Remove unsupported customFiltersKai Köhne2021-09-061-3/+1
| | | | | | | | | | customFilters defined in .qdocconf are not supported anymore by Qt Assistant since Qt 5.13. Therefore remove them from all .qdocconf files, also to avoid cargo-culting them to new help modules. Task-number: QTBUG-95987 Change-Id: I83562b30c2fa039b7a207caaf7b3705ae0e4aa70 Reviewed-by: Paul Wicking <paul.wicking@qt.io>
* QtCMake Manual: Fix index titleKai Köhne2021-08-251-1/+1
| | | | | | | | | | Make sure that selecting "Build with CMake" in assistant shows the landing page. Pick-to: 6.2 6.1 Change-Id: I4d0a8ac114a809fab2ac23cc1b4417ff471a64da Reviewed-by: Nicholas Bennett <nicholas.bennett@qt.io> Reviewed-by: Paul Wicking <paul.wicking@qt.io>
* CMake: Mention CMake 3.21.1 requirement in overviewKai Köhne2021-08-191-0/+2
| | | | | | | | See https://lists.qt-project.org/pipermail/development/2021-August/041710.html Pick-to: 6.2 Change-Id: I91443883c67b683f49e7d22f6529d1d17aff02b3 Reviewed-by: Alexandru Croitor <alexandru.croitor@qt.io>
* List QtRemoteObjects CMake docs in the table of contents for CMake docsSona Kurazyan2021-08-061-0/+1
| | | | | | | | | Pick-to: 6.2 Task-number: QTBUG-95433 Change-Id: I1883676c27ba4562822398240f32c8a14da0cd59 Reviewed-by: Mårten Nordheim <marten.nordheim@qt.io> Reviewed-by: Brett Stottlemyer <bstottle@ford.com> Reviewed-by: Paul Wicking <paul.wicking@qt.io>
* Simplify discussion of CMAKE_PREFIX_PATHCraig Scott2021-07-211-8/+3
| | | | | | | | | | | | The CMAKE_PREFIX_PATH cache variable is how we should recommend new users locate Qt. Environment variables are not traceable and the cache variable would silently override the environment variable anyway if both were given. Task-number: QTBUG-95271 Pick-to: 6.2 Change-Id: I3b37816b3753da51f2299ff12ee044694b7dd076 Reviewed-by: Kai Koehne <kai.koehne@qt.io>
* Add sections for QML commands and variables in the CMake manualCraig Scott2021-07-212-0/+11
| | | | | | Pick-to: 6.2 Change-Id: Id8e0d144807c1e12e629870fb811dd2a1a65f158 Reviewed-by: Kai Koehne <kai.koehne@qt.io>
* Move Qt6::Scxml CMake commands index to its correctly sorted positionCraig Scott2021-07-211-6/+6
| | | | | | | Pick-to: 6.2 Change-Id: I7d1ed6e2f0e220aea1c2a0a757ef35aa342226a2 Reviewed-by: Alexandru Croitor <alexandru.croitor@qt.io> Reviewed-by: Kai Koehne <kai.koehne@qt.io>
* cmake: Rename 'Get started' to 'Getting started'Kai Köhne2021-06-091-4/+4
| | | | | | | | This is how the section is called in other manuals. Pick-to: 6.1 6.2 Change-Id: I309470b91680039899384fb9d12c723da6f2d0d5 Reviewed-by: Paul Wicking <paul.wicking@qt.io>
* Add information about the disabling of UNICODE macros in WindowsAlexey Edelev2021-05-212-0/+22
| | | | | | | | | Pick-to: 6.1 Task-number: QTBUG-93895 Task-number: QTBUG-89951 Change-Id: I8b76c29be84ffa6073c0958b4cc1fe9592d7ce9a Reviewed-by: Leena Miettinen <riitta-leena.miettinen@qt.io> Reviewed-by: Alexandru Croitor <alexandru.croitor@qt.io>