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. Can't build sample apps
Qt 6.11 is out! See what's new in the release blog

Can't build sample apps

Scheduled Pinned Locked Moved General and Desktop
6 Posts 4 Posters 3.5k 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.
  • X Offline
    X Offline
    xris
    wrote on last edited by
    #1

    Hi there,

    I'm new to QT and I'm trying to get the environment up and running. I've installed the Complete SDK for Windows and I get the following whenever I try to compile anything. I've installed on Mac and Linux without issue.

    It looks like the makefile is trying to use a path associated with the local user account, but I'm at a loss as to where the referencing is coming from. The username of the account is "Husband & Wife" (with spaces and &). Qt is installed in the default location from the installer: c:\Qt...

    Any ideas what is going wrong and how I can fix it?

    @Running build steps for project draggabletext...
    Starting: "c:/qt/2010.05/qt/bin/qmake.exe" C:/Qt/2010.05/qt/examples/draganddrop/draggabletext/draggabletext.pro -r -spec win32-g++
    The process "c:/qt/2010.05/qt/bin/qmake.exe" exited normally.
    Starting: "C:/Qt/2010.05/mingw/bin/mingw32-make.exe" -w
    mingw32-make: Entering directory `C:/Qt/2010.05/qt/examples/draganddrop/draggabletext-build-desktop'

    C:/Qt/2010.05/mingw/bin/mingw32-make -f Makefile.Debug all

    mingw32-make[1]: Entering directory `C:/Qt/2010.05/qt/examples/draganddrop/draggabletext-build-desktop'

    g++ -c -g -frtti -fexceptions -mthreads -Wall -DUNICODE -DQT_LARGEFILE_SUPPORT -DQT_DLL -DQT_GUI_LIB -DQT_CORE_LIB -DQT_THREAD_SUPPORT -DQT_NEEDS_QMAIN -I"......\include\QtCore" -I"......\include\QtGui" -I"......\include" -I"......\include\ActiveQt" -I"tmp\moc\debug_shared" -I"..\draggabletext" -I"." -I"......\mkspecs\win32-g++" -o tmp\obj\debug_shared\draglabel.o ..\draggabletext\draglabel.cpp

    mingw32-make[1]: Leaving directory `C:/Qt/2010.05/qt/examples/draganddrop/draggabletext-build-desktop'

    mingw32-make: Leaving directory `C:/Qt/2010.05/qt/examples/draganddrop/draggabletext-build-desktop'

    'C:\Users\CHRIS' is not recognized as an internal or external command,

    operable program or batch file.

    The system cannot find the path specified.

    mingw32-make[1]: *** [tmp/obj/debug_shared/draglabel.o] Error 1

    mingw32-make: *** [debug-all] Error 2

    The process "C:/Qt/2010.05/mingw/bin/mingw32-make.exe" exited with code %2.
    Error while building project draggabletext (target: Desktop)
    When executing build step 'Make'@

    1 Reply Last reply
    0
    • X Offline
      X Offline
      xris
      wrote on last edited by
      #2

      Ok, solved it myself. Apparently it didn't like the TEMP (or TMP) folder having an '&' in it. The old value was C:\Users\CHRIS&~1\AppData\Local\Temp

      I changed it to c:\temp (and created that folder) and the problems went away.

      Should I file a bug for this? It's a proper 8.3 file path name in Windows.

      1 Reply Last reply
      0
      • A Offline
        A Offline
        andre
        wrote on last edited by
        #3

        If you do, the bug would probably be against mingw32, not Qt.

        In my experience, you save yourself a whole lot of trouble if you stick to paths without anything special: no spaces, no special characters, preferably not too long. There is always a tool somewhere in the chain that seems to choke on things like that.

        1 Reply Last reply
        0
        • Z Offline
          Z Offline
          ZapB
          wrote on last edited by
          #4

          Agreed, spaces in filenames are evil ;-)

          Nokia Certified Qt Specialist
          Interested in hearing about Qt related work

          1 Reply Last reply
          0
          • T Offline
            T Offline
            tobias.hunger
            wrote on last edited by
            #5

            ZapB: It is so sad that this is still true in the 21st century:-(

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

              I agree. Sadly we have to live with such things. I find it less painful to use no-spaces in paths as a rule of thumb to avoid nasty surprises when trying to use tools that do not properly quote and/or escape special characters.

              Nokia Certified Qt Specialist
              Interested in hearing about Qt related work

              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