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. Building Qt from Git
Forum Updated to NodeBB v4.3 + New Features

Building Qt from Git

Scheduled Pinned Locked Moved General and Desktop
32 Posts 3 Posters 11.9k Views 1 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.
  • sierdzioS Offline
    sierdzioS Offline
    sierdzio
    Moderators
    wrote on last edited by
    #6

    That should be working, then. You may have encountered a bug.

    (Z(:^

    1 Reply Last reply
    0
    • M Offline
      M Offline
      Mechatronic
      wrote on last edited by
      #7

      I will try to repeat all sequence and report about result. Thanks a lot.

      1 Reply Last reply
      0
      • M Offline
        M Offline
        Mechatronic
        wrote on last edited by
        #8

        I tryed, but error is still here

        1 Reply Last reply
        0
        • JKSHJ Offline
          JKSHJ Offline
          JKSH
          Moderators
          wrote on last edited by
          #9

          Hi,

          Did you clean your build tree before you tried to start a new build?

          Qt Doc Search for browsers: forum.qt.io/topic/35616/web-browser-extension-for-improved-doc-searches

          1 Reply Last reply
          0
          • M Offline
            M Offline
            Mechatronic
            wrote on last edited by
            #10

            Hi,
            I cleared build dirrectory before new build.
            I tryed to build Qt on other PC with the same version of Ubuntu and it builded successfully. Obviosly, problem is in concrete enviroment.

            1 Reply Last reply
            0
            • M Offline
              M Offline
              Mechatronic
              wrote on last edited by
              #11

              After build I tryed to install Qt and got many errors like:
              @
              make[3]: Entering directory /home/user/qt5/qtbase/src/tools/bootstrap' install -m 644 -p "../../../lib/libQt5Bootstrap.a" "/home/user/qt5/qtbase/lib/libQt5Bootstrap.a" install: ../../../lib/libQt5Bootstrap.a' and `/home/user/qt5/qtbase/lib/libQt5Bootstrap.a' are the same file
              make[3]: [install_target] Error 1 (ignored)
              @

              please, help me

              1 Reply Last reply
              0
              • sierdzioS Offline
                sierdzioS Offline
                sierdzio
                Moderators
                wrote on last edited by
                #12

                Developer builds should not be installed, configure explicitly warns against doing that!

                (Z(:^

                1 Reply Last reply
                0
                • M Offline
                  M Offline
                  Mechatronic
                  wrote on last edited by
                  #13

                  Why build is "development" if I took stable branch?
                  And what i shoud do to use builded Qt?

                  1 Reply Last reply
                  0
                  • M Offline
                    M Offline
                    Mechatronic
                    wrote on last edited by
                    #14

                    I did all like in http://qt-project.org/wiki/Building_Qt_5_from_Git guide. And guide say
                    @
                    To install, run
                    make install
                    @

                    1 Reply Last reply
                    0
                    • sierdzioS Offline
                      sierdzioS Offline
                      sierdzio
                      Moderators
                      wrote on last edited by
                      #15

                      You use -developer-build flag. That implies building with a prefix set to $PWD/qtbase, which does not require installation (once it is build it is also installed).

                      If the guide advises to install it after doing a developer build, then the guide is wrong. But just to be sure, please run the configure and see what it prints. If installation is not necessary, it will explicitly say so.

                      (Z(:^

                      1 Reply Last reply
                      0
                      • M Offline
                        M Offline
                        Mechatronic
                        wrote on last edited by
                        #16

                        You are right. I do not delete " -developer-build" flag. Thank you.
                        What should I do to use it now with Qt Creator? Qt Creator uses Qt 4.8 now.

                        1 Reply Last reply
                        0
                        • sierdzioS Offline
                          sierdzioS Offline
                          sierdzio
                          Moderators
                          wrote on last edited by
                          #17

                          Go to Tools->Preferences->Build & Run->Qt Versions and click "Add", then browse to your qmake binary (it's in <Qt dir>/qtbase/bin). That will add Qt to Qt Creator, but in order to use it, you need to create or modify an existing Kit.

                          So, go to Kits tab and add a new one: you need to specify the compiler (the one you have used to compile Qt. If you use g++ and clang, they are binary compatible, so you can choose any of them) and your newly added Qt version.

                          After that, Qt Creator will be fully configured. You can start using that Kit in your projects (open your project, go to Projects pane and add the new Kit).

                          (Z(:^

                          1 Reply Last reply
                          0
                          • M Offline
                            M Offline
                            Mechatronic
                            wrote on last edited by
                            #18

                            when I add qmake, message "The default mkspec symlink is broken" appeared in status bar of "Qt Versions" tab. Is it critical?

                            1 Reply Last reply
                            0
                            • sierdzioS Offline
                              sierdzioS Offline
                              sierdzio
                              Moderators
                              wrote on last edited by
                              #19

                              I have never encountered that. Try if it works.

                              You have not cleared your Qt directory after erroneously running "make install"? It might have broken some paths. But if it works, you are fine. If it does not, you can try overriding MKSPECS in Qt Creator's Kit settings.

                              (Z(:^

                              1 Reply Last reply
                              0
                              • M Offline
                                M Offline
                                Mechatronic
                                wrote on last edited by
                                #20

                                No, it is not works - I can not chose Qt5 build configuration for new project.
                                There is not "Kits" tab, but there is "Tool chains" tab. And there is "auto-detected" group, which contain GCC 64 and 32 bit.
                                What is MKSPECS?

                                1 Reply Last reply
                                0
                                • M Offline
                                  M Offline
                                  Mechatronic
                                  wrote on last edited by
                                  #21

                                  may be it will explain something :
                                  output of "qmake -query"
                                  @QT_INSTALL_PREFIX:/usr
                                  QT_INSTALL_DATA:/usr/share/qt4
                                  QT_INSTALL_DOCS:/usr/share/qt4/doc
                                  QT_INSTALL_HEADERS:/usr/include/qt4
                                  QT_INSTALL_LIBS:/usr/lib/x86_64-linux-gnu
                                  QT_INSTALL_BINS:/usr/bin
                                  QT_INSTALL_PLUGINS:/usr/lib/x86_64-linux-gnu/qt4/plugins
                                  QT_INSTALL_IMPORTS:/usr/lib/x86_64-linux-gnu/qt4/imports
                                  QT_INSTALL_TRANSLATIONS:/usr/share/qt4/translations
                                  QT_INSTALL_CONFIGURATION:/etc/xdg
                                  QT_INSTALL_EXAMPLES:/usr/lib/qt4/examples
                                  QT_INSTALL_DEMOS:/usr/lib/qt4/demos
                                  QMAKE_MKSPECS:/usr/share/qt4/mkspecs
                                  QMAKE_VERSION:2.01a
                                  QT_VERSION:4.8.2
                                  @

                                  1 Reply Last reply
                                  0
                                  • sierdzioS Offline
                                    sierdzioS Offline
                                    sierdzio
                                    Moderators
                                    wrote on last edited by
                                    #22

                                    Oh, you are probably using an old version of Qt Creator, that is unfortunate. I advise an update.

                                    mkspecs is a thing Qt uses as a guide on how to create Makefiles for different platforms and compilers. You can take a look at how it looks like in <Qt dir>/qtbase/mkspecs.

                                    In your case, you probably need to specify linux-g++.

                                    (Z(:^

                                    1 Reply Last reply
                                    0
                                    • M Offline
                                      M Offline
                                      Mechatronic
                                      wrote on last edited by
                                      #23

                                      and this is putput of
                                      " /home/user/qt5/qtbase/bin/qmake -query"
                                      @
                                      QT_SYSROOT:
                                      QT_INSTALL_PREFIX:/home/user/qt5/qtbase
                                      QT_INSTALL_ARCHDATA:/home/user/qt5/qtbase
                                      QT_INSTALL_DATA:/home/user/qt5/qtbase
                                      QT_INSTALL_DOCS:/home/user/qt5/qtbase/doc
                                      QT_INSTALL_HEADERS:/home/user/qt5/qtbase/include
                                      QT_INSTALL_LIBS:/home/user/qt5/qtbase/lib
                                      QT_INSTALL_LIBEXECS:/home/user/qt5/qtbase/libexec
                                      QT_INSTALL_BINS:/home/user/qt5/qtbase/bin
                                      QT_INSTALL_TESTS:/home/user/qt5/qtbase/tests
                                      QT_INSTALL_PLUGINS:/home/user/qt5/qtbase/plugins
                                      QT_INSTALL_IMPORTS:/home/user/qt5/qtbase/imports
                                      QT_INSTALL_QML:/home/user/qt5/qtbase/qml
                                      QT_INSTALL_TRANSLATIONS:/home/user/qt5/qtbase/translations
                                      QT_INSTALL_CONFIGURATION:/home/user/qt5/qtbase/etc/xdg
                                      QT_INSTALL_EXAMPLES:/home/user/qt5/qtbase/examples
                                      QT_INSTALL_DEMOS:/home/user/qt5/qtbase/examples
                                      QT_HOST_PREFIX:/home/user/qt5/qtbase
                                      QT_HOST_DATA:/home/user/qt5/qtbase
                                      QT_HOST_BINS:/home/user/qt5/qtbase/bin
                                      QT_HOST_LIBS:/home/user/qt5/qtbase/lib
                                      QMAKE_SPEC:linux-g++
                                      QMAKE_XSPEC:linux-g++
                                      QMAKE_VERSION:3.0
                                      QT_VERSION:5.3.0
                                      @

                                      Please, tell, why new qmake is not used as default, if build == install in developer build?

                                      1 Reply Last reply
                                      0
                                      • M Offline
                                        M Offline
                                        Mechatronic
                                        wrote on last edited by
                                        #24

                                        isn't Qt Creator in Qt git repository? should I download it separately?

                                        1 Reply Last reply
                                        0
                                        • sierdzioS Offline
                                          sierdzioS Offline
                                          sierdzio
                                          Moderators
                                          wrote on last edited by
                                          #25

                                          Qt does not add itself to PATH, especially developer builds. This allows you to use multiple versions of Qt in parallel, which is extremely useful.

                                          You can add it to PATH by hand, of course. Qt Creator does not need that, though: it automatically modifies the environment of binaries it executes.

                                          (Z(:^

                                          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