[CMake] [PATCH] FindQt4.cmake qt4_automoc improvements

Andreas Pakulat apaku at gmx.de
Tue May 20 10:13:44 EDT 2008


On 20.05.08 14:56:57, Tanguy Krotoff wrote:
> On Tue, May 20, 2008 at 10:29 AM, Andreas Pakulat <apaku at gmx.de> wrote:
> > Yes they are and AFAIK there's a policy within TT that you can't use the
> > "short" form for any public header. The same thing is true for KDE's
> > kdelibs module, no public header is allowed to #include <QMainWindow>
> > they all have to work with just passing -I/some/path/to/qt/include.
> 
> Do you know why this policy is not followed by *_p.h and *.cpp files?

Because its not needed, compilation of the .cpp and _p.h files in the Qt
sources is under the control of Trolltech (for KDE its likewise under
control of the kde devs), so they (we) can make sure that the
buildsystem sets the needed include paths for using just #include
<QWidget>. 

The problem with installed/public header files is that you never know
who uses them with what buildsystem and wether or not he/his buildsystem
sets the needed additional include paths. So its important that when one
public header include's another one he does this in a way that
compilation of some third party sources only fails if there's no -I
switch for Qt at all.

Andreas

-- 
Keep emotionally active.  Cater to your favorite neurosis.


More information about the CMake mailing list