Uploaded image for project: 'Qt Creator'
  1. Qt Creator
  2. QTCREATORBUG-30082

Improvements to Qt Creator MCU new project template

    XMLWordPrintable

Details

    Description

      The root project should always be a qmlproject, not a CMake project

      Under the root project, there can be multiple targets: always at least desktop, but also any number of MCUs.

      In the project creation wizard, the user could choose one or several targets, which would trigger qmlprojectexporter to add all the needed platform files under a subfolder (or other configurable folder) for that target, and also containing a standalone CMake project itself referencing the root qmlproject. It would also create the kit for that target and associate it with the sub-project.

      A mockup of how this could look like has been drafted here:

      Embedded content

      Should QUL core sources export be a dependency?

      For each target sub-project, a different set of QUL core libs should be included. If QUL sources are available in the Qt for MCUs install folder (full commercial), they should be copied in each target sub-project (this would allow different configurations for different targets). If QUL sources are not available (eval), the sub-project should link to pre-built binaries.

      Other features:

      1. The active target should be highlighted in in the project explorer, and an action should be available to change the active target, which would also automatically update the active kit
      2. When changing the kit, the active sub-project in the project explorer should automatically be updated to match
      3. Add or remove target sub-projects from a root project, which would also add or remove kits associated with the project
      4. Optional: a way to upgrade a target's platform sources with a newer version. If the sources in the application have changed, a warning should be given, asking if the user wants to replace the old platform sources with the new ones from Qt for MCUs. We could be using Qt Creator's diff viewer to compare the difference, and use some tool to do the merge. If not implemented, the user would simply have to do this upgrade manually with the tools of their choice.
      5. Optional: upgrade all standard examples/demos/tests to use that structure and approach. At the very least, we need to test in CI the approach from this template.
      6. Action to export the root project to another IDE
      7. A way to switch a target sub-project's QUL libs configuration: use prebuilt QUL libs or include QUL core sources

      The MCU template project in Qt Creator could be improved with the following:

      ​Both "empty" and "full" templates:

      • A 'main.cpp' file should be included, rather than relying on the auto-generated one from the 'GENERATE_ENTRYPOINT' option

      Only 'full' template:

      • The CustomModule should also include a .cpp file to demonstrate UL-8355
      • The C++ backend should be split as separate .h and .cpp files
      • Following the approach in the QDS project template, there could be a Constants module

      Attachments

        No reviews matched the request. Check your Options in the drop-down menu of this sections header.

        Activity

          People

            ylopes Yoann Lopes
            ylopes Yoann Lopes
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

              Created:
              Updated:

              Gerrit Reviews

                There are no open Gerrit changes