[Development] Help with build failure on Windows
Chris Meyer
cmeyer1969+qt at gmail.com
Tue Aug 6 07:18:43 CEST 2013
On Mon, Aug 5, 2013 at 8:27 PM, Thiago Macieira
<thiago.macieira at intel.com>wrote:
> On segunda-feira, 5 de agosto de 2013 19:51:00, Chris Meyer wrote:
> > I assume that means that it includes the qdesktopwidget.h file (which I
> > _do_ see is properly included)... but how does it know to include
> > qdesktopwidget_qpa_p.h (or even qdesktopwidget_p.h), neither of which I
> see
> > included? via the Q_DECLARE_PRIVATE macro?
>
> It doesn't.
>
> > I don't see _any_ private header files get included from moc files, and
> yet
> > they seem to be required for the Q_PRIVATE_SLOT macro... so I don't
> > understand this yet.
>
> For a Q_PRIVATE_SLOT macro to work, which requires access to the private
> header, the moc output must be #included at the end of the .cpp file.
I'm understanding more... but there is still something I don't understand.
Don't the moc_*.cpp files get compiled directly too? How does qmake know
not to generate Makefile instructions to directly compile the moc_*.cpp
files that use Q_PRIVATE_SLOT? If it were to compile them directly, it
would be missing the private headers, which was the error I was seeing.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.qt-project.org/pipermail/development/attachments/20130805/ea126992/attachment.html>
More information about the Development
mailing list