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. [solved]Error while compiling project with "QMake"
QtWS25 Last Chance

[solved]Error while compiling project with "QMake"

Scheduled Pinned Locked Moved General and Desktop
16 Posts 7 Posters 45.5k 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
    Cameron
    wrote on last edited by
    #1

    Hey guys. relatively noobish Qt user here :P

    a friend of mine and I have been working on a code editor, being created with Qt. For collaboration purposes, we use DropBox to sync our files together, then load the project from there. It runs fine on his computer (Win7), but I get this error when I try to compile (I've tried on XP, Ubuntu and Jolicloud):

    @Running build steps for project CodeProgram...
    Starting: "/home/cameron/qt/qt/bin/qmake" /home/cameron/Dropbox/Code Program/CodeProgram/CodeProgram.pro -r -spec linux-g++ CONFIG+=debug
    Failure to open file: /usr/share/jolicloud-daemon/htdocs/Makefile
    Unable to generate makefile for: /home/cameron/Dropbox/Code Program/CodeProgram/CodeProgram.pro
    The process "/home/cameron/qt/qt/bin/qmake" exited with code %2.
    Error while building project CodeProgram (target: Desktop)
    When executing build step 'qmake'@

    The only guess I have for this is that it's a problem with the OS bit rate, i think his Win7 version runs 64 while all 3 OS' i tested on happened to run on a 32 bit OS.

    Note - this only happens when loading this project, I created my own to test it and it compiles fine.

    Thanks for any help in advance.

    1 Reply Last reply
    0
    • B Offline
      B Offline
      blex
      wrote on last edited by
      #2

      @
      Failure to open file: /usr/share/jolicloud-daemon/htdocs/Makefile
      @

      Are you sure that path exists and permissions are sufficient?

      Also, you have a white-space in the path near the "Code Program". Try to remove it.


      Oleksiy Balabay

      1 Reply Last reply
      0
      • D Offline
        D Offline
        dfaure
        wrote on last edited by
        #3

        The question is why is it trying to generate a Makefile in /usr, this doesn't make sense ;)
        Can you post the contents of the CodeProgram.pro file?

        David Faure (david.faure@kdab.com)
        KDE/Qt Senior Software Engineer
        KDAB - Qt Experts - Platform-independent software solutions

        1 Reply Last reply
        0
        • G Offline
          G Offline
          goetz
          wrote on last edited by
          #4

          The Makefile is generated in the current working dir, not in the dir where the .pro file is. So I'd guess he is in /usr/share/jolicloud-daemon/htdocs when he calls qmake.

          http://www.catb.org/~esr/faqs/smart-questions.html

          1 Reply Last reply
          0
          • L Offline
            L Offline
            lyuts
            wrote on last edited by
            #5

            I would suggest you using version control system instead of DropBox. VCS is designed for that.

            I'm a rebel in the S.D.G.

            1 Reply Last reply
            0
            • C Offline
              C Offline
              Cameron
              wrote on last edited by
              #6

              Thanks for the feedback guys.

              @#-------------------------------------------------

              Project created by QtCreator 2010-11-07T12:08:25

              #-------------------------------------------------

              QT += core gui

              TARGET = CodeProgram
              TEMPLATE = app

              SOURCES += main.cpp
              mainwindow.cpp
              codeeditor.cpp
              preferences.cpp
              highlighter.cpp

              HEADERS += mainwindow.h
              codeeditor.h
              preferences.h
              highlighter.h

              FORMS += mainwindow.ui
              preferences.ui

              RESOURCES +=
              Resources.qrc

              OTHER_FILES +=
              @

              that's the .pro file

              1 Reply Last reply
              0
              • I Offline
                I Offline
                IrQX
                wrote on last edited by
                #7

                Have you tried
                @make clean
                qmake
                ..@
                ?

                And what means OTHER_FILES in your *.pro file? If it blank - remove this line from file, and try again.

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

                  [quote author="IrQX" date="1290934842"]Have you tried
                  @make clean
                  qmake
                  ..@
                  ?

                  And what means OTHER_FILES in your *.pro file? If it blank - remove this line from file, and try again.[/quote]

                  I dunno, didn't notice that. Thanks for pointing that out, will try now.

                  1 Reply Last reply
                  0
                  • C Offline
                    C Offline
                    Cameron
                    wrote on last edited by
                    #9

                    didn't seem to work.

                    @IrQX - could you please explain more in-depth what you mean by "make clean"?

                    1 Reply Last reply
                    0
                    • G Offline
                      G Offline
                      goetz
                      wrote on last edited by
                      #10

                      @
                      make clean
                      @

                      is a command that you enter in your shell. Usually a Makefile contains a target clean to remove all intermediate files (.o object files, moc- and uic-generated files) and the the final executable or lib.

                      What is your current working dir (i.e. what dir are you in), when you call qmake? You must be in the dir containing the .pro file.

                      http://www.catb.org/~esr/faqs/smart-questions.html

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

                        As you see in the first post where I pasted the error message, the .pro file is in

                        @/home/cameron/Dropbox/Code Program/CodeProgram/CodeProgram.pro@

                        but Qt is searching for the "Qmake" in

                        @/home/cameron/qt/qt/bin/qmake@

                        also, i'm not running this in terminal or anything. i just clicked the green "run" arrow in the left sidebar.

                        1 Reply Last reply
                        0
                        • G Offline
                          G Offline
                          goetz
                          wrote on last edited by
                          #12

                          You did not mention that you use Qt Creator, so we suggested you use the command line tools.

                          What are the settings of your project page? Of special interest are the paths (shadow build, build directory).

                          http://www.catb.org/~esr/faqs/smart-questions.html

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

                            Oh my....Official failure on my part.

                            I didn't know that Qt kept a static build directory, so the QMake dir was set to his computer's. I changed and it works perfectly now.

                            sorry for all the trouble, and thanks for the great support!

                            1 Reply Last reply
                            0
                            • G Offline
                              G Offline
                              goetz
                              wrote on last edited by
                              #14

                              No problem, you're welcome - that's what these forums are for.

                              http://www.catb.org/~esr/faqs/smart-questions.html

                              1 Reply Last reply
                              0
                              • M Offline
                                M Offline
                                maissiou23
                                wrote on last edited by
                                #15

                                try to delete the root folders generated by QT when compiling.
                                let say your project path is: C:/KK/Project. Then you just need to delete C:/KK/Project-Build... This way you delete old QT configurations saved inside these build folders (which may not be compatible with you're current config).

                                1 Reply Last reply
                                0
                                • G Offline
                                  G Offline
                                  goetz
                                  wrote on last edited by
                                  #16

                                  No necroposting, please. There's no need to wake the dead - the thread had its last response for more than one year ago and it was resolved already. Thanks.

                                  http://www.catb.org/~esr/faqs/smart-questions.html

                                  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