Qt Forum

    • Login
    • Search
    • Categories
    • Recent
    • Tags
    • Popular
    • Users
    • Groups
    • Search
    • Unsolved

    Update: Forum Guidelines & Code of Conduct


    Qt World Summit: Early-Bird Tickets

    Solved Building of some projects with subdirs template in creator

    Tools
    2
    5
    416
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • K
      koahnig last edited by

      I am using a cascade of subdir templates. The upper level is holding two projects, one for the main application and one for the dlls. The dll project is also based on subdirs template and has a couple of projects for different dlls.

      In creator you can right click on any project it shows as upper entry Build "project name". Therefore I expect that the build will include only projects in that specific branch.

      Currently I have the case that when building only the dll branch or even one of the dlls also the main application project is compiled and linked. Build window shows that qt creator steps through all projects.

      IIRC that worked in the past but in my installation anymore. Any opinion is welcome.

      Vote the answer(s) that helped you to solve your issue(s)

      kshegunov 1 Reply Last reply Reply Quote 0
      • kshegunov
        kshegunov Moderators @koahnig last edited by kshegunov

        What I do is after I run the root project file and make (to propagate the Makefile generation) I load in creator only the specific leaf projects I'm interested in (i.e. one of the libs and an application, say). Then I use the "Import existing build ..." to configure the project and finally I set the dependency in Creator's project config pane (as it doesn't respect the .depends from the .pro files). Works pretty well in my case. I avoid loading a whole root project in Creator because it often can get really big with many libraries and applications.

        Read and abide by the Qt Code of Conduct

        K 1 Reply Last reply Reply Quote 3
        • K
          koahnig @kshegunov last edited by

          @kshegunov

          Not sure if I understand your approach completely.

          Certainly I can load the .pro of the dll subproject separately or any of its subprojects directly into creator. That should work.
          However, what is the purpose of "Import existing build ..."?
          Is it because of duplication between object files of complete and leaf projects?

          Vote the answer(s) that helped you to solve your issue(s)

          kshegunov 1 Reply Last reply Reply Quote 0
          • kshegunov
            kshegunov Moderators @koahnig last edited by kshegunov

            @koahnig said in Building of some projects with subdirs template in creator:

            Is it because of duplication between object files of complete and leaf projects?

            Sort of, it imports the command line configuration for the output directories and such. So in the end it behaves pretty much as what you'd expect by building through the shell. Also it helps to make sure each project references the proper kit, read Qt version, (i.e. the one used when you build from the command line).

            Read and abide by the Qt Code of Conduct

            K 1 Reply Last reply Reply Quote 3
            • K
              koahnig @kshegunov last edited by

              @kshegunov said in Building of some projects with subdirs template in creator:

              @koahnig said in Building of some projects with subdirs template in creator:

              Is it because of duplication between object files of complete and leaf projects?

              Sort of, it imports the command line configuration for the output directories and such. So in the end it behaves pretty much as what you'd expect by building through the shell. Also it helps to make sure each project references the proper kit, read Qt version, (i.e. the one used when you build from the command line).

              OK, that seems to work for me as well.

              Is there any relevant documentation available? Searching for some without success.

              There is in the left pane this
              0_1568971015640_401e354e-6240-4133-8031-2dbc966a6441-image.png
              which I used. But in the right window there is also
              0_1568971066750_5a3d274e-5274-4bf6-bd6d-3b6976b74de2-image.png
              They end in the same folder which cannot be chosen in my case. It has to be the shadow build folder resp the relevant branch in that case.
              There might be special condition since I try to separate source and shadow build folders as much as possible. The reason is internal, in addition I am using a RAM folder as shadow for a while.

              @kshegunov Thanks for the hint it is really helpful.

              Vote the answer(s) that helped you to solve your issue(s)

              1 Reply Last reply Reply Quote 1
              • First post
                Last post