Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. Installation and Deployment
  4. Qt Creator Compile Error with mingw32-make on Windows
QtWS25 Last Chance

Qt Creator Compile Error with mingw32-make on Windows

Scheduled Pinned Locked Moved Installation and Deployment
18 Posts 3 Posters 10.0k Views
  • 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.
  • C Offline
    C Offline
    CodeGnome
    wrote on last edited by
    #1

    Hello,

    I have installed qt 5.1.0 and am trying to compile qt creator. I have downloaded the source code for qt creator and run qmake qtcreator.pro which generates a Makefile. I then run mingw32-make which generates the following error (scroll to bottom to see the error codes):

    Creating library file: C:\qt-creator-qt-creator\lib\qtcreator\libAggregation.a
    release/aggregate.o:aggregate.cpp:(.text+0xc): undefined reference to _imp___ZN 14QReadWriteLockD1Ev' release/aggregate.o:aggregate.cpp:(.text+0x49): undefined reference to _imp___Z
    N9QHashData11free_helperEPFvPNS_4NodeEE'
    release/aggregate.o:aggregate.cpp:(.text+0x7d): undefined reference to `_imp___Z

    Removed Lines due to 6000 limit

    release/aggregate.o:aggregate.cpp:(.text$_ZN6QDebugD1Ev[QDebug::~QDebug()]+0x3c)
    : undefined reference to _imp___ZN11QTextStreamD1Ev' release/aggregate.o:aggregate.cpp:(.text$_ZN6QDebugD1Ev[QDebug::~QDebug()]+0x6e) : undefined reference to _imp___Z17qt_message_output9QtMsgTypeRK18QMessageLogCo
    ntextRK7QString'

    Removed Lines due to 6000 Limit

    release/moc_aggregate.o:moc_aggregate.cpp:(.rdata$_ZTVN11Aggregation9AggregateE[
    vtable for Aggregation::Aggregate]+0x34): undefined reference to QObject::disco nnectNotify(QMetaMethod const&)' collect2: ld returned 1 exit status mingw32-make[3]: *** [..\..\..\lib\qtcreator\Aggregation.dll] Error 1 mingw32-make[3]: Leaving directory c:/qt-creator-qt-creator/src/libs/aggregatio
    n'
    mingw32-make[2]: *** [release] Error 2
    mingw32-make[2]: Leaving directory c:/qt-creator-qt-creator/src/libs/aggregatio n' mingw32-make[1]: *** [sub-libs-aggregation-make_first-ordered] Error 2 mingw32-make[1]: Leaving directory c:/qt-creator-qt-creator/src'
    mingw32-make: *** [sub-src-make_first-ordered] Error 2

    I'm not sure what the problem is, but if anyone has an idea please let me know.
    Thank you.

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

      Are you using the same compiler that was used to build Qt?

      (Z(:^

      1 Reply Last reply
      0
      • C Offline
        C Offline
        CodeGnome
        wrote on last edited by
        #3

        I installed the precompiled build on the download page:
        Qt 5.1.0 for Windows 64-bit (VS 2012, OpenGL, 522 MB)

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

          MSVC and MinGW compilers are not compatible. You need to go with either one, but not both.

          (Z(:^

          1 Reply Last reply
          0
          • C Offline
            C Offline
            CodeGnome
            wrote on last edited by
            #5

            Hmm... I'd like to use Visual Studio, but I'm having trouble using custom plugins in qt creator if I use the default installed version. Is it true that I must recompile with MinGW in order to use custom plugins? There was some error about keys being invalid.

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

              I don't know that. Qt Creator does not have stable plugin interface, so it's likely that you need a recompile.

              (Z(:^

              1 Reply Last reply
              0
              • K Offline
                K Offline
                koahnig
                wrote on last edited by
                #7

                Concerning the creator plugin plugin question I have started a "similar thread":http://qt-project.org/forums/viewthread/30805/ without success/response yet.

                The readme shipped with qt creator states:
                [quote]
                This section provides step by step instructions for compiling the latest
                versions of Qt and Qt Creator on Windows. Alternatively, to avoid having to
                compile Qt yourself, you can use one of the versions of Qt shipped with the Qt
                SDK (release builds of Qt using MinGW and Visual C++ 2008).
                [/quote]

                The reference to mingw is not specific in view of version. For vc it is. Since vc is not compatible between different versions (at least 2010 downward), you need to recompile when you intend to use msvc2012.

                For MinGW I could not find a proper reference which version has been used or if MinGW has been used at all for qt creator in the MinGW 5.1 distro.

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

                1 Reply Last reply
                0
                • C Offline
                  C Offline
                  CodeGnome
                  wrote on last edited by
                  #8

                  I'm currently re-compiling Qt on my computer now with Visual Studio, jom, perl, and python. After this, I will try to compile the source for qt creator and see if it works since everything was compiled on my own machine.

                  Currently, Qt 5.1.0 appears to be compiling correctly (I made sure that perl, python, and jom were in the path list in the environment variables for windows). I'll update when it's done and I try to go at qt create again.

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

                    Good luck to you, then :)

                    (Z(:^

                    1 Reply Last reply
                    0
                    • C Offline
                      C Offline
                      CodeGnome
                      wrote on last edited by
                      #10

                      It's working now :)

                      1 Reply Last reply
                      0
                      • C Offline
                        C Offline
                        CodeGnome
                        wrote on last edited by
                        #11

                        I'm going to compile the plugins now and see if they work also. So close!

                        1 Reply Last reply
                        0
                        • C Offline
                          C Offline
                          CodeGnome
                          wrote on last edited by
                          #12

                          I spoke too soon, when finish compiling the qt creator I get the following error:
                          @
                          copy /y "......\lib\qtcreator\ExtensionSystemd.dll" ......\bin
                          1 file(s) copied.
                          cd utils\ && ( if not exist Makefile C:\qt-everywhere-opensource-src-5.1.0\qtbase\bin\qmake.exe C:\qt-creator-2.8.0-src\src\libs\utils\utils.pro -o Make
                          file ) && "C:\Program Files (x86)\Microsoft Visual Studio 11.0\VC\BIN\nmake.exe" -f Makefile
                          Project ERROR: Unknown module(s) in QT: script
                          NMAKE : fatal error U1077: 'cd' : return code '0x3'
                          Stop.
                          NMAKE : fatal error U1077: 'cd' : return code '0x2'
                          Stop.
                          NMAKE : fatal error U1077: 'cd' : return code '0x2'
                          Stop.
                          @
                          [edit, code tags added, koahnig]

                          1 Reply Last reply
                          0
                          • C Offline
                            C Offline
                            CodeGnome
                            wrote on last edited by
                            #13

                            Anyone have any ideas? I've still not gotten this to work. Could it be a missing environment variable?

                            1 Reply Last reply
                            0
                            • K Offline
                              K Offline
                              koahnig
                              wrote on last edited by
                              #14

                              What is the command you started?
                              Where did you start it?

                              Without knowing more details, I guess that you have not started nmake from vc command prompt, but outside.
                              [edit, that should correlate with your assumption on environment setting]

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

                              1 Reply Last reply
                              0
                              • C Offline
                                C Offline
                                CodeGnome
                                wrote on last edited by
                                #15

                                Sorry, I opened the VS2012 x86 Native Tools Command Prompt to compile qt 5.1.0 which worked. I reopened the same console and was trying to compile qt creator 2.8.0

                                1 Reply Last reply
                                0
                                • C Offline
                                  C Offline
                                  CodeGnome
                                  wrote on last edited by
                                  #16

                                  So I read http://qt-project.org/doc/qt-5.0/qtdoc/modules.html and am thinking that I must not have some required module link since the compiler says Unknown module(s) in the error output. Is there some way I can find out what module it is missing? How would I link the correct module to the compiler?

                                  Sorry for such noob questions!

                                  1 Reply Last reply
                                  0
                                  • K Offline
                                    K Offline
                                    koahnig
                                    wrote on last edited by
                                    #17

                                    [quote author="CodeGnome" date="1375893957"]
                                    Sorry for such noob questions![/quote]

                                    No problem, we are all somewhere noobs.

                                    I would guess if you have compiled Qt with standard settings you should be alright. If you fiddled around with some special settings during configure, that could be an issue.

                                    I have done a compilation of qt creator 2.8 (and 2.7.2) end of last week without problems. It was merely the waiting time. However, I have used Qt 5.1.0 MinGW pre-built. Therefore, I think default settings for Qt libs, you should be fine for creator. However, this could be now related to your vs2012 compiler.
                                    Thinking a bit more, may be it is a nmake issue. You could give jom a shot. At least it should not be a time-consuming side track.

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

                                    1 Reply Last reply
                                    0
                                    • K Offline
                                      K Offline
                                      koahnig
                                      wrote on last edited by
                                      #18

                                      Here is the "download page for jom":http://qt-project.org/wiki/jom

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

                                      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