Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. General and Desktop
  4. define 'Shadow Build' directory in .pro file
Forum Updated to NodeBB v4.3 + New Features

define 'Shadow Build' directory in .pro file

Scheduled Pinned Locked Moved Unsolved General and Desktop
12 Posts 3 Posters 1.1k Views 2 Watching
  • 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.
  • SGaistS Offline
    SGaistS Offline
    SGaist
    Lifetime Qt Champion
    wrote on last edited by
    #2

    Hi,

    It'd not something you define at the .pro file level. A shadow build is simply an out of source build.

    Interested in AI ? www.idiap.ch
    Please read the Qt Code of Conduct - https://forum.qt.io/topic/113070/qt-code-of-conduct

    1 Reply Last reply
    3
    • R Offline
      R Offline
      RodrigoCanellas
      wrote on last edited by
      #3

      Ok, I understand.

      I need to place all the Makefile in a different directory, just like the Shadow Build does.

      Is there anyway to do it?

      jsulmJ 1 Reply Last reply
      0
      • R RodrigoCanellas

        Ok, I understand.

        I need to place all the Makefile in a different directory, just like the Shadow Build does.

        Is there anyway to do it?

        jsulmJ Offline
        jsulmJ Offline
        jsulm
        Lifetime Qt Champion
        wrote on last edited by
        #4

        @RodrigoCanellas said in define 'Shadow Build' directory in .pro file:

        Is there anyway to do it?

        Yes, out of source build, just like @SGaist already wrote.

        mkdir build_folder
        cd build_folder
        qmake ../project_folder
        make
        

        https://forum.qt.io/topic/113070/qt-code-of-conduct

        1 Reply Last reply
        1
        • R Offline
          R Offline
          RodrigoCanellas
          wrote on last edited by RodrigoCanellas
          #5
          This post is deleted!
          1 Reply Last reply
          0
          • R Offline
            R Offline
            RodrigoCanellas
            wrote on last edited by
            #6

            I meant in the common.pri file

            jsulmJ 1 Reply Last reply
            0
            • R RodrigoCanellas

              I meant in the common.pri file

              jsulmJ Offline
              jsulmJ Offline
              jsulm
              Lifetime Qt Champion
              wrote on last edited by
              #7

              @RodrigoCanellas Why would you define build folder inside project file? Especially if more than one person is working on a project that can lead to problems.

              https://forum.qt.io/topic/113070/qt-code-of-conduct

              1 Reply Last reply
              1
              • R Offline
                R Offline
                RodrigoCanellas
                wrote on last edited by
                #8

                The idea is that this configuration can be commited to a version control (like git), and every developer can get it, regardless the QtCreator configuration, which stays, AFIK, in a file that can not be in a versioned directory. If a developer does not turn on Shadow Build and/or set Build Path correctly, can lead to build erros.

                jsulmJ 1 Reply Last reply
                0
                • R RodrigoCanellas

                  The idea is that this configuration can be commited to a version control (like git), and every developer can get it, regardless the QtCreator configuration, which stays, AFIK, in a file that can not be in a versioned directory. If a developer does not turn on Shadow Build and/or set Build Path correctly, can lead to build erros.

                  jsulmJ Offline
                  jsulmJ Offline
                  jsulm
                  Lifetime Qt Champion
                  wrote on last edited by
                  #9

                  @RodrigoCanellas I never saw a project storing path to build folder inside project configuration to be honest. A developer should be able to set build folder properly the way he/she wants it to be.

                  https://forum.qt.io/topic/113070/qt-code-of-conduct

                  1 Reply Last reply
                  0
                  • R Offline
                    R Offline
                    RodrigoCanellas
                    wrote on last edited by RodrigoCanellas
                    #10

                    Ok, I accept defeat... and what about the variables used in Build & Run/Default build directory , like Kit:FileSystemName and BuildConfig:Name? Would you know where can I get a list of these variables? I think I can get a result closer to the one I wanted, by using them.

                    More precisely, I would like to define something like build/<platform>-<architecture>-<configuration>, producing build/win-x64-debug.

                    Thanks for your help!

                    jsulmJ 1 Reply Last reply
                    0
                    • R RodrigoCanellas

                      Ok, I accept defeat... and what about the variables used in Build & Run/Default build directory , like Kit:FileSystemName and BuildConfig:Name? Would you know where can I get a list of these variables? I think I can get a result closer to the one I wanted, by using them.

                      More precisely, I would like to define something like build/<platform>-<architecture>-<configuration>, producing build/win-x64-debug.

                      Thanks for your help!

                      jsulmJ Offline
                      jsulmJ Offline
                      jsulm
                      Lifetime Qt Champion
                      wrote on last edited by
                      #11

                      @RodrigoCanellas For qmake variables see: https://doc.qt.io/qt-5/qmake-variable-reference.html
                      For QtCreator check this: https://stackoverflow.com/questions/35970727/use-of-variables-like-builddir-in-qtcreator-kit-settings-in-qt5

                      https://forum.qt.io/topic/113070/qt-code-of-conduct

                      1 Reply Last reply
                      2
                      • R Offline
                        R Offline
                        RodrigoCanellas
                        wrote on last edited by RodrigoCanellas
                        #12

                        Thanks a lot!

                        I think I'll be able to do what I want through % variables, but it seems the A->B button does not show the entire list, and I could not find what possible values for <value> in, for example, Compile:Name:<value>.

                        I saw now the Debugger:Abi, which in my case evaluates in x86-darwin-generic-mach_o-64bit arm-darwin-generic-mach_o-64bit. I do not know why it reports the two CPU architectures supported by the compiler, even though the current Kit defines x86.

                        If there was a way to access the current ABI, may be through %Kit variable, and then to access each part of the ABI definition, that would do it.

                        1 Reply Last reply
                        0

                        • Login

                        • Login or register to search.
                        • First post
                          Last post
                        0
                        • Categories
                        • Recent
                        • Tags
                        • Popular
                        • Users
                        • Groups
                        • Search
                        • Get Qt Extensions
                        • Unsolved