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. You cannot configure qt separately within a top-level build
Forum Updated to NodeBB v4.3 + New Features

You cannot configure qt separately within a top-level build

Scheduled Pinned Locked Moved Solved General and Desktop
18 Posts 6 Posters 4.9k 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.
  • V Offline
    V Offline
    Vivx701
    wrote on 23 May 2018, 10:49 last edited by Vivx701
    #1

    I am getting this error continuously while trying to build Qt5.9.5 source for Raspberry-Pi 3. What can be the possible reason ?
    log is given below.

    Target os: Fedberry 27
    Toolchain: gcc-linaro-7.2.1-2017.11-x86_64_arm-linux-gnueabihf/

    bash-4.4$ ../configure -recheck-all -opengl es2 -device linux-rasp-pi2-g++ -device-option CROSS_COMPILE=/home/alokin/raspberry/gcc-linaro-7.2.1-2017.11-x86_64_arm-linux-gnueabihf/bin/arm-linux-gnueabihf- -sysroot /mnt/raspberry-rootfs -opensource -confirm-license -optimized-qmake -reduce-exports -release -make libs -prefix /usr -hostprefix /usr/local/Qt_5_9_5raspberry/ -skip qtwebengine

    • cd qtbase
    • /home/alokin/Qt5.9/qt-everywhere-opensource-src-5.9.5/qtbase/configure -top-level -recheck-all -opengl es2 -device linux-rasp-pi2-g++ -device-option CROSS_COMPILE=/home/alokin/raspberry/gcc-linaro-7.2.1-2017.11-x86_64_arm-linux-gnueabihf/bin/arm-linux-gnueabihf- -sysroot /mnt/raspberry-rootfs -opensource -confirm-license -optimized-qmake -reduce-exports -release -make libs -prefix /usr -hostprefix /usr/local/Qt_5_9_5raspberry/ -skip qtwebengine
      Preparing build tree...
      Creating qmake...
      ........................................................................................Done.
      Project ERROR: You cannot configure qt separately within a top-level build.
    1 Reply Last reply
    0
    • V Offline
      V Offline
      Vivx701
      wrote on 24 May 2018, 13:40 last edited by Vivx701
      #16

      hello guys , finally iam able to build Qt after making two blank files named
      1.) .qmake.stash
      2.) .qmake.super
      in build directory. So the problem is happening due to not creating this two files in the configuring step. I don't know why configuring script is behaving like this.

      1 Reply Last reply
      5
      • M Offline
        M Offline
        mrjj
        Lifetime Qt Champion
        wrote on 23 May 2018, 11:03 last edited by
        #2

        Hi
        You are not stating Qt version, platform etc so hard to geuss at.

        Might be this ?
        https://bugreports.qt.io/browse/QTBUG-56049

        V 1 Reply Last reply 23 May 2018, 11:43
        0
        • M mrjj
          23 May 2018, 11:03

          Hi
          You are not stating Qt version, platform etc so hard to geuss at.

          Might be this ?
          https://bugreports.qt.io/browse/QTBUG-56049

          V Offline
          V Offline
          Vivx701
          wrote on 23 May 2018, 11:43 last edited by
          #3

          @mrjj But i don't have any .qmake.super file in my directory

          P 1 Reply Last reply 23 May 2018, 13:07
          0
          • V Vivx701
            23 May 2018, 11:43

            @mrjj But i don't have any .qmake.super file in my directory

            P Offline
            P Offline
            Pablo J. Rogina
            wrote on 23 May 2018, 13:07 last edited by
            #4

            @Vivx701 it looks like you're trying to cross compile (-device-option CROSS_COMPILE=...) so are you following this guide? It worked for me with Raspbian Stretch, Qt 5.10.1 and Pi Zero W
            Just in case, you stated "for Raspberry-Pi 3" but you shown configurating it for RPi 2 -> "-device linux-rasp-pi2-g++"

            Upvote the answer(s) that helped you solve the issue
            Use "Topic Tools" button to mark your post as Solved
            Add screenshots via postimage.org
            Don't ask support requests via chat/PM. Please use the forum so others can benefit from the solution in the future

            V 1 Reply Last reply 23 May 2018, 13:39
            1
            • P Pablo J. Rogina
              23 May 2018, 13:07

              @Vivx701 it looks like you're trying to cross compile (-device-option CROSS_COMPILE=...) so are you following this guide? It worked for me with Raspbian Stretch, Qt 5.10.1 and Pi Zero W
              Just in case, you stated "for Raspberry-Pi 3" but you shown configurating it for RPi 2 -> "-device linux-rasp-pi2-g++"

              V Offline
              V Offline
              Vivx701
              wrote on 23 May 2018, 13:39 last edited by
              #5

              @Pablo-J.-Rogina Iam not building for rasbian . My target os is fedberry

              P 1 Reply Last reply 23 May 2018, 13:42
              0
              • V Vivx701
                23 May 2018, 13:39

                @Pablo-J.-Rogina Iam not building for rasbian . My target os is fedberry

                P Offline
                P Offline
                Pablo J. Rogina
                wrote on 23 May 2018, 13:42 last edited by
                #6

                @Vivx701 said in You cannot configure qt separately within a top-level build:

                fedberry

                Ok, it would be better to have stated it previously :-) (saving you and me a couple of posts...)

                Even with that, I guess the suggested guide would still apply from step #5 onwards, wouldn't it?

                Upvote the answer(s) that helped you solve the issue
                Use "Topic Tools" button to mark your post as Solved
                Add screenshots via postimage.org
                Don't ask support requests via chat/PM. Please use the forum so others can benefit from the solution in the future

                V 1 Reply Last reply 23 May 2018, 13:49
                0
                • P Pablo J. Rogina
                  23 May 2018, 13:42

                  @Vivx701 said in You cannot configure qt separately within a top-level build:

                  fedberry

                  Ok, it would be better to have stated it previously :-) (saving you and me a couple of posts...)

                  Even with that, I guess the suggested guide would still apply from step #5 onwards, wouldn't it?

                  V Offline
                  V Offline
                  Vivx701
                  wrote on 23 May 2018, 13:49 last edited by
                  #7

                  @Pablo-J.-Rogina : Still it gives the same error.

                  P 1 Reply Last reply 23 May 2018, 13:58
                  0
                  • V Vivx701
                    23 May 2018, 13:49

                    @Pablo-J.-Rogina : Still it gives the same error.

                    P Offline
                    P Offline
                    Pablo J. Rogina
                    wrote on 23 May 2018, 13:58 last edited by
                    #8

                    @Vivx701 @Vivx701 Wow! it looks like you were super fast creating your sysroot and rscync'ing it.
                    Again, my suggestion is that you follow that guide step by step...

                    Upvote the answer(s) that helped you solve the issue
                    Use "Topic Tools" button to mark your post as Solved
                    Add screenshots via postimage.org
                    Don't ask support requests via chat/PM. Please use the forum so others can benefit from the solution in the future

                    V 1 Reply Last reply 23 May 2018, 13:59
                    0
                    • P Pablo J. Rogina
                      23 May 2018, 13:58

                      @Vivx701 @Vivx701 Wow! it looks like you were super fast creating your sysroot and rscync'ing it.
                      Again, my suggestion is that you follow that guide step by step...

                      V Offline
                      V Offline
                      Vivx701
                      wrote on 23 May 2018, 13:59 last edited by Vivx701
                      #9

                      @Pablo-J.-Rogina : I just mounted my sd card under /mnt/raspberry-rootfs

                      P 1 Reply Last reply 23 May 2018, 14:01
                      0
                      • V Vivx701
                        23 May 2018, 13:59

                        @Pablo-J.-Rogina : I just mounted my sd card under /mnt/raspberry-rootfs

                        P Offline
                        P Offline
                        Pablo J. Rogina
                        wrote on 23 May 2018, 14:01 last edited by
                        #10

                        @Vivx701 Ok, it's up to you. All I can say it's the guide helped me achieving the goal of cross-compiling Qt for RPi
                        Roger over and out!

                        Upvote the answer(s) that helped you solve the issue
                        Use "Topic Tools" button to mark your post as Solved
                        Add screenshots via postimage.org
                        Don't ask support requests via chat/PM. Please use the forum so others can benefit from the solution in the future

                        1 Reply Last reply
                        1
                        • SGaistS Offline
                          SGaistS Offline
                          SGaist
                          Lifetime Qt Champion
                          wrote on 23 May 2018, 14:15 last edited by
                          #11

                          Hi,

                          You seem to be building Qt from within a directory that's inside the sources, is that correct ?

                          If so, then that's likely the problem. You should build Qt either within the top folder of the sources or even better in a folder outside of the sources.

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

                          V 2 Replies Last reply 23 May 2018, 14:31
                          2
                          • SGaistS SGaist
                            23 May 2018, 14:15

                            Hi,

                            You seem to be building Qt from within a directory that's inside the sources, is that correct ?

                            If so, then that's likely the problem. You should build Qt either within the top folder of the sources or even better in a folder outside of the sources.

                            V Offline
                            V Offline
                            Vivx701
                            wrote on 23 May 2018, 14:31 last edited by
                            #12

                            @SGaist Now i created a directory outside Qt source code and tried running this . see the output at the end same error.

                            bash-4.4$ ../qt-everywhere-opensource-src-5.9.5/configure -recheck-all -opengl es2 -device linux-rasp-pi3-g++ -device-option CROSS_COMPILE=/home/alokin/raspberry/gcc-linaro-7.2.1-2017.11-x86_64_arm-linux-gnueabihf/bin/arm-linux-gnueabihf- -sysroot /mnt/raspberry-rootfs -opensource -confirm-license -optimized-qmake -reduce-exports -release -make libs -prefix /usr/local/Qt_595-raspberry/ -qt-libpng -qt-zlib -qt-libjpeg -qt-pcre -qt-freetype -skip qtwebengine -force-debug-info -nomake tests

                            • cd qtbase
                            • /home/alokin/Qt5.9/qt-everywhere-opensource-src-5.9.5/qtbase/configure -top-level -recheck-all -opengl es2 -device linux-rasp-pi3-g++ -device-option CROSS_COMPILE=/home/alokin/raspberry/gcc-linaro-7.2.1-2017.11-x86_64_arm-linux-gnueabihf/bin/arm-linux-gnueabihf- -sysroot /mnt/raspberry-rootfs -opensource -confirm-license -optimized-qmake -reduce-exports -release -make libs -prefix /usr/local/Qt_595-raspberry/ -qt-libpng -qt-zlib -qt-libjpeg -qt-pcre -qt-freetype -skip qtwebengine -force-debug-info -nomake tests
                              Preparing build tree...
                              Creating qmake...
                              .Done.
                              Project ERROR: You cannot configure qt separately within a top-level build.
                            1 Reply Last reply
                            0
                            • SGaistS SGaist
                              23 May 2018, 14:15

                              Hi,

                              You seem to be building Qt from within a directory that's inside the sources, is that correct ?

                              If so, then that's likely the problem. You should build Qt either within the top folder of the sources or even better in a folder outside of the sources.

                              V Offline
                              V Offline
                              Vivx701
                              wrote on 23 May 2018, 14:41 last edited by
                              #13

                              @SGaist This time iam trying to build with in Qt source code directory , see the output . same error

                              ./configure -recheck-all -opengl es2 -device linux-rasp-pi3-g++ -device-option CROSS_COMPILE=/home/alokin/raspberry/gcc-linaro-7.2.1-2017.11-x86_64_arm-linux-gnueabihf/bin/arm-linux-gnueabihf- -sysroot /mnt/raspberry-rootfs -opensource -confirm-license -optimized-qmake -reduce-exports -release -make libs -prefix /usr/local/Qt_595-raspberry/ -qt-libpng -qt-zlib -qt-libjpeg -qt-pcre -qt-freetype -skip qtwebengine -force-debug-info -nomake tests

                              • cd qtbase
                              • /home/alokin/Qt5.9/qt-everywhere-opensource-src-5.9.5/qtbase/configure -top-level -recheck-all -opengl es2 -device linux-rasp-pi3-g++ -device-option CROSS_COMPILE=/home/alokin/raspberry/gcc-linaro-7.2.1-2017.11-x86_64_arm-linux-gnueabihf/bin/arm-linux-gnueabihf- -sysroot /mnt/raspberry-rootfs -opensource -confirm-license -optimized-qmake -reduce-exports -release -make libs -prefix /usr/local/Qt_595-raspberry/ -qt-libpng -qt-zlib -qt-libjpeg -qt-pcre -qt-freetype -skip qtwebengine -force-debug-info -nomake tests
                                Creating qmake...
                                .Done.
                                Project ERROR: You cannot configure qt separately within a top-level build.
                              1 Reply Last reply
                              0
                              • SGaistS Offline
                                SGaistS Offline
                                SGaist
                                Lifetime Qt Champion
                                wrote on 23 May 2018, 20:19 last edited by
                                #14

                                Are you doing that from clean sources ?

                                If not, you should nuke them as well as the build folders you used and start over with 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

                                V 1 Reply Last reply 24 May 2018, 04:46
                                1
                                • SGaistS SGaist
                                  23 May 2018, 20:19

                                  Are you doing that from clean sources ?

                                  If not, you should nuke them as well as the build folders you used and start over with an out of source build.

                                  V Offline
                                  V Offline
                                  Vivx701
                                  wrote on 24 May 2018, 04:46 last edited by
                                  #15

                                  @SGaist This is the source https://download.qt.io/archive/qt/5.9/5.9.5/single/qt-everywhere-opensource-src-5.9.5.tar.xz

                                  1 Reply Last reply
                                  0
                                  • V Offline
                                    V Offline
                                    Vivx701
                                    wrote on 24 May 2018, 13:40 last edited by Vivx701
                                    #16

                                    hello guys , finally iam able to build Qt after making two blank files named
                                    1.) .qmake.stash
                                    2.) .qmake.super
                                    in build directory. So the problem is happening due to not creating this two files in the configuring step. I don't know why configuring script is behaving like this.

                                    1 Reply Last reply
                                    5
                                    • X Offline
                                      X Offline
                                      xion0202
                                      wrote on 11 Aug 2020, 20:34 last edited by
                                      #17

                                      Adding .qmake.super seemed that have fixed my issue as well. Has anyone found out why it wasn't created to begin with?

                                      1 Reply Last reply
                                      1
                                      • A Offline
                                        A Offline
                                        AdrianFK
                                        wrote on 3 Jan 2021, 02:24 last edited by
                                        #18

                                        Cloned GIT folder into Mint Linux 20, I had a failed configure in the root directory. Removed .qmake.super file from the root QT5 folder, then configured again within the QT5-build folder without error.

                                        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