H
H
horror_x2012-07-25 23:58:24
Qt
horror_x, 2012-07-25 23:58:24

Unusual behavior of qmake - bug or feature?

I work with Qt 4.8.2 together with MSVC 2008, I generate projects like this:

qmake.exe -spec win32-msvc2008 -r -tp vc projects.pro

I noticed that declaring header files by mask in pro-files works crookedly or does not work at all if the “qt” flag is excluded from CONFIG.
For example, the following code in a project:
CONFIG -= qt
HEADERS = *.h
SOURCES = *.cpp

Causes no h-files to appear in the MSVC project, "*.h" is added instead (the same usually happens if there are no h-files). But it is worth removing the first line, and everything works fine.
In the documentation , the "qt" flag is described as follows:
The project is a Qt application and should link against the Qt library. You can use the QT variable to control any additional Qt modules that are required by your application.

Is this a bug or am I missing something?

Answer the question

In order to leave comments, you need to log in

1 answer(s)
S
Stanislav, 2012-07-26
@horror_x

Congratulations, it looks like you found a bug :) Write to the bug tracker. For now, you can get around
HEADERS = $$files(*.h)

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question