Uploaded image for project: 'Qt'
  1. Qt
  2. QTBUG-42903

Regression: Can't use gcc command line "-include myglobal.h"

    XMLWordPrintable

Details

    • Bug
    • Resolution: Done
    • Not Evaluated
    • 5.4.0
    • 5.4.0
    • Build tools: qmake
    • None
    • KUbuntu 14.04, Qt 5.4 from Git

    Description

      I have QMAKE_CXXFLAGS += "-include myglobal.h" in my .pro file. The file myglobal.h itself contains some global defines and inline Qt code. With Qt 5.3 compilation works fine. With 5.4 it fails with the eror:

      ./myglobal.h:6:21: fatal error: QMetaType: No such file or directory

      The problem is in Makefile in compiling QRC file.

      With Qt 5.3 the resource file has been compiled with rcc, and then with gcc $(CXXFLAGS) $(INCFLAGS).

      With Qt 5.4 gcc is called without $(INCPATH), as a result Qt includes are not available, and gcc fails.

      Attachments

        No reviews matched the request. Check your Options in the drop-down menu of this sections header.

        Activity

          People

            hjk hjk
            dmitry64 Dmitry
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:

              Gerrit Reviews

                There are no open Gerrit changes