[Qt-interest] qmake does not support headers without a corresponding source file

Kustaa Nyholm Kustaa.Nyholm at planmeca.com
Fri May 28 09:12:11 CEST 2010


Sorry, replied to Thiago, when I of course meant to reply to the list


> Header-only classes are supported, no problem.
> 
> The problem is header-only projects. The qmake "app" or "lib" templates
> require building something, so they need source code, not just headers, to
> build.
> 
Can you expand on that a little bit, what is a header only project?

My project is pretty standard Qt project with dozens of
xxx.h/xxxp.cpp/xxx.ui triplets. In one those .ui files (say A.ui)
I use mywidget. The uic compiles the A.ui to ui_A.h file which contains
'#include <mywidget.h>' correctly and automagically but no depency is
generated for for that include in the Makefile.

br Kusti





More information about the Qt-interest-old mailing list