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. Qt 5.0.1 for Windows 32-bit (MinGW 4.7) example project compilation error
Qt 6.11 is out! See what's new in the release blog

Qt 5.0.1 for Windows 32-bit (MinGW 4.7) example project compilation error

Scheduled Pinned Locked Moved General and Desktop
13 Posts 4 Posters 12.4k 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.
  • Z Offline
    Z Offline
    zhanisch
    wrote on last edited by
    #4

    I have similar problem. I got similar error messages with any new created project (Qt gui or console) on Windows 7 64 bit platform. I am using Qt 5.0.1 with 32 bit mingw. On linux it is working well.

    21:02:08: Running steps for project qt5_gui...
    21:02:08: Starting: "C:\Qt\Qt5.0.1\5.0.1\mingw47_32\bin\qmake.exe" C:\Users\Zoltan\Documents\Programming\qt5_gui\qt5_gui.pro -r -spec win32-g++ "CONFIG+=debug" "CONFIG+=declarative_debug" "CONFIG+=qml_debug"
    21:02:09: The process "C:\Qt\Qt5.0.1\5.0.1\mingw47_32\bin\qmake.exe" exited normally.
    21:02:09: Starting: "C:\Qt\Qt5.0.1\Tools\MinGW\bin\mingw32-make.exe"
    C:/Qt/Qt5.0.1/Tools/MinGW/bin/mingw32-make -f Makefile.Debug
    mingw32-make[1]: Entering directory 'C:/Users/Zoltan/Documents/Programming/qt5_gui-build-Desktop_Qt_5_0_1_MinGW_32bit-Debug'
    C:\Qt\Qt5.0.1\5.0.1\mingw47_32\bin\uic.exe ..\qt5_gui\mainwindow.ui -o ui_mainwindow.h
    g++ -c -pipe -fno-keep-inline-dllexport -g -frtti -Wall -Wextra -fexceptions -mthreads -DUNICODE -DQT_QML_DEBUG -DQT_DECLARATIVE_DEBUG -DQT_WIDGETS_LIB -DQT_GUI_LIB -DQT_CORE_LIB -DQT_OPENGL_ES_2 -DQT_OPENGL_ES_2_ANGLE -DQT_NEEDS_QMAIN -I..\qt5_gui -I"..........\Qt\Qt5.0.1\5.0.1\mingw47_32\include" -I"..........\Qt\Qt5.0.1\5.0.1\mingw47_32\include\QtWidgets" -I"..........\Qt\Qt5.0.1\5.0.1\mingw47_32\include\QtGui" -I"..........\Qt\Qt5.0.1\5.0.1\mingw47_32\include\QtCore" -I"debug" -I"." -I"." -I"..........\Qt\Qt5.0.1\5.0.1\mingw47_32\mkspecs\win32-g++" -o debug\main.o ..\qt5_gui\main.cpp
    g++.exe: error: ..qt5_guimain.cpp: No such file or directory
    g++.exe: fatal error: no input files
    compilation terminated.
    Makefile.Debug:357: recipe for target 'debug/main.o' failed
    mingw32-make[1]: *** [debug/main.o] Error 1
    mingw32-make[1]: Leaving directory 'C:/Users/Zoltan/Documents/Programming/qt5_gui-build-Desktop_Qt_5_0_1_MinGW_32bit-Debug'
    makefile:34: recipe for target 'debug' failed
    mingw32-make: *** [debug] Error 2
    21:02:11: The process "C:\Qt\Qt5.0.1\Tools\MinGW\bin\mingw32-make.exe" exited with code 2.
    Error while building/deploying project qt5_gui (kit: Desktop Qt 5.0.1 MinGW 32bit)
    When executing step 'Make'

    1 Reply Last reply
    0
    • ? Offline
      ? Offline
      A Former User
      wrote on last edited by
      #5

      OK. It works with Win XP 32-bit also. Win 7 64-bit seems to be the problem for this 5.0.1.

      1 Reply Last reply
      0
      • Z Offline
        Z Offline
        zhanisch
        wrote on last edited by
        #6

        I have found the problem!
        I installed the GIT (on Windows) before! I removed from path the GIT and the compilation is working fine!

        1 Reply Last reply
        0
        • ? Offline
          ? Offline
          A Former User
          wrote on last edited by
          #7

          Okey, but I don't have GIT installation and path does not include any GIT relations.

          1 Reply Last reply
          0
          • Z Offline
            Z Offline
            zhanisch
            wrote on last edited by
            #8

            I've double checked. When I put the Git into the PATH and created a new project, I couldn't compile it. If I removed from PATH, the compilation was successful.
            I suspect that your PATH contains a program that has not compatible program with mingw or Qt 5.0. I don't know.

            I've found that sh.exe is the not compatible component in the GIT/bin folder.

            1 Reply Last reply
            0
            • ? Offline
              ? Offline
              A Former User
              wrote on last edited by
              #9

              I totally removed the path variables from user variables and system variables. After that example project started to work. Then I started to put the same values back, one by one, to the path variables to solve which one causes the problem. Now I have exactly the same contents in path variables as in start but now it seems to work with those values ?

              So removing the paths and putting them back again did the trick ? Don't know how this is possible but now it works..

              1 Reply Last reply
              0
              • Z Offline
                Z Offline
                zhanisch
                wrote on last edited by
                #10

                The trick is after successful compilation the problematic and not compatible program won't be called. If you delete the build directory (debug and release) you can get the same error message. I suggest that you should find the problematic folder/program. Maybe the sh.exe in a folder.

                1 Reply Last reply
                0
                • ? Offline
                  ? Offline
                  A Former User
                  wrote on last edited by
                  #11

                  Yes, I have noticed that also. New projects does not compile anymore with the existing path variables (Clean all and Rebuild all is not enough). I have to find out which path variable causes this.

                  1 Reply Last reply
                  0
                  • ? Offline
                    ? Offline
                    A Former User
                    wrote on last edited by
                    #12

                    Okey. I think I have found the problem in my workstation. I have uninstalled the OpenSSH for Windows 3.8.1p1-1 (or something). Uninstall removes also the \OpenSSH\bin variable from path. After this all the projects has been working as they should.

                    1 Reply Last reply
                    0
                    • ? Offline
                      ? Offline
                      A Former User
                      wrote on last edited by
                      #13

                      OpenSSH in my PATH was also the problem. Thanks.

                      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