summaryrefslogtreecommitdiffstats
path: root/Help/prop_tgt
diff options
context:
space:
mode:
authorSebastian Holtermann <sebholt@xwmw.org>2016-04-18 18:09:23 (GMT)
committerBrad King <brad.king@kitware.com>2016-04-22 12:49:21 (GMT)
commit8295d43713b621558ce8fc67033021e6eb2a6612 (patch)
tree6be23ac691d0cae3c59badb7e8dacacacf6408ff /Help/prop_tgt
parentd350308af6704e70f94ef00d45c4b52ad779e566 (diff)
downloadCMake-8295d43713b621558ce8fc67033021e6eb2a6612.zip
CMake-8295d43713b621558ce8fc67033021e6eb2a6612.tar.gz
CMake-8295d43713b621558ce8fc67033021e6eb2a6612.tar.bz2
Autogen: Check added for name collisions of generated moc files
The test exits with an error if two or more source files would generate the same moc file.
Diffstat (limited to 'Help/prop_tgt')
-rw-r--r--Help/prop_tgt/AUTOMOC.rst8
1 files changed, 7 insertions, 1 deletions
diff --git a/Help/prop_tgt/AUTOMOC.rst b/Help/prop_tgt/AUTOMOC.rst
index bd1ace8..8143ba9 100644
--- a/Help/prop_tgt/AUTOMOC.rst
+++ b/Help/prop_tgt/AUTOMOC.rst
@@ -13,7 +13,13 @@ source files at build time and invoke moc accordingly.
* If an ``#include`` statement like ``#include "moc_foo.cpp"`` is found,
the ``Q_OBJECT`` class declaration is expected in the header, and
- ``moc`` is run on the header file.
+ ``moc`` is run on the header file. A ``moc_foo.cpp`` file will be
+ generated from the source's header into the
+ :variable:`CMAKE_CURRENT_BINARY_DIR` directory. This allows the
+ compiler to find the included ``moc_foo.cpp`` file regardless of the
+ location the original source. However, if multiple source files
+ in different directories do this then their generated moc files would
+ collide. In this case a diagnostic will be issued.
* If an ``#include`` statement like ``#include "foo.moc"`` is found,
then a ``Q_OBJECT`` is expected in the current source file and ``moc``