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

Cmake superproject with several subprojects

    XMLWordPrintable

Details

    • Bug
    • Resolution: Out of scope
    • Not Evaluated
    • None
    • Qt Creator 4.15.0
    • None
    • CentOS8, cmake 3.20.2, QtCreator 5.15.0
    • Linux/X11

    Description

      I would like to create a Cmake superproject which call several subprojects.

       

      To do that, I add the following command in my cmake superproject:

      add_subdirectory(source_dir binary_dir) where:

      source_dir=/absolute/path/to/my/subproject

      binary_dir=subproject_name

       

      In this case, I have several issues:

      1 - The source file of the subprojects don't appear in the project manager tree

      2 - If my superproject contains only 1 subproject, the superproject works well. The table of couples (Key, Value) in cmake compiler parameters contains parameters of this subproject. I can build the whole superproject.

      3 - If my superproject contains several subprojects,  I have several issues in this case. The table of couples (Key, Value) in cmake compiler parameters contains only parameters of the first subproject. Therefore, the second subproject don't build.

       

      Attachments

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

        Activity

          People

            cadam Cristian Adam
            phfr83 phfr83
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:

              Gerrit Reviews

                There are no open Gerrit changes