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. QMake and make with parallel jobs [bug?]

QMake and make with parallel jobs [bug?]

Scheduled Pinned Locked Moved General and Desktop
8 Posts 6 Posters 13.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.
  • U Offline
    U Offline
    UrsusExplorans
    wrote on last edited by
    #1

    Hi folks,

    is seems like theres is a bug in the Makefile generation of qmake. When running make after qmake as usual, I get no errors, but running it with multiple jobs, lets say "make -j3", I get the following error:

    @make: *** No rule to make target ../../../ui/ui_something.h', needed by something.o'. Stop.
    make: *** Waiting for unfinished jobs....@

    It looks like, that the uic does not finish before the other parallel compile jobs start. Is there a way to fix this (I mean not by starting make twice)?

    Thanks in advance!

    Best,
    Eckard

    1 Reply Last reply
    0
    • V Offline
      V Offline
      vsorokin
      wrote on last edited by
      #2

      As far as I know, qmake run before make, and while qmake work is not done, make don't start.
      -j key does not affect on qmake.

      --
      Vasiliy

      1 Reply Last reply
      0
      • U Offline
        U Offline
        UrsusExplorans
        wrote on last edited by
        #3

        No, of course. But qmake seems to write the uic calls into the makefile that make processes. Using make with the -j argument parallelizes the execution of the makefile to a certain extend. But make does not seem to care about the uic calls correctly, because it executes the following compile commands without waiting for the uic calls to be finished (which result in the upper error message).

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

          This sounds like a bug to me. Have you considered filing it in our "bugtracker":http://bugreports.qt.nokia.com/ ?

          1 Reply Last reply
          0
          • U Offline
            U Offline
            UrsusExplorans
            wrote on last edited by
            #5

            created a new issue:

            "QTBUG-12139":http://bugreports.qt.nokia.com/browse/QTBUG-12139

            1 Reply Last reply
            0
            • K Offline
              K Offline
              kalle
              wrote on last edited by
              #6

              Not sure whether this is the same problem, but did you try CONFIG+=ordered?

              In general, if you need high parallelity in your builds, CMake is much more powerful than QMake.

              1 Reply Last reply
              0
              • D Offline
                D Offline
                Dii
                wrote on last edited by
                #7

                I use qmake and make -j4 for ages, never had that problem. I read about a similar problem somewhere, there were some unnecessary #include-s of the same files across the project, and that made some trouble. I don't know if it has anything to do with your problem.

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

                  I'm using qmake together with make -j8 on several projects for years without any hazzle (including speeding up compilation of my project in Creator).

                  For me it's CMake that causes problems with parallel builds. But since I rarely use that, it's not a real issue for me.

                  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