| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
|
|
|
|
|
| |
This should finally fix #13667 and #13762.
Instead of adding special handling to guess whether implicit include dirs
may have been removed, simply make it possible to query the include dirs
without removing the implicit ones.
Alex
|
|\
| |
| |
| |
| | |
d253657 Automoc: fix regression #13667, broken build in phonon
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
On some systems, ${QT_INCLUDE_DIR} is reported by gcc as a builtin
include search dir. Some projects use this information to extend
CMAKE_CXX_IMPLICIT_INCLUDE_DIRECTORIES.
In cmake 2.8.10 now the targets are queried for the include directories
they use. When they return the result, the include dirs contained in
CMAKE_CXX_IMPLICIT_INCLUDE_DIRECTORIES have been removed.
In cmake 2.8.9 and below the INCLUDE_DIRECTORIES directory property
was queried, where this had not been stripped.
So, in those projects which modify the implicit include dirs variable,
on systems where ${QT_INCLUDE_DIR} is reported by gcc, this directory,
e.g. /usr/lib/include/qt/, was not given anymore to moc. This made moc
not find required headers, so the build broke.
Simply giving the full CMAKE_CXX_IMPLICIT_INCLUDE_DIRECTORIES to moc
is no solution either, since moc can't handle some of the headers it
finds then (https://bugreports.qt-project.org/browse/QTBUG-28045).
So now cmake checks CMAKE_CXX_IMPLICIT_INCLUDE_DIRECTORIES, and if this
contains ${QT_INCLUDE_DIR}, and the target reports that it uses
${QT_QTCORE_INCLUDE_DIR} but not ${QT_INCLUDE_DIR}, ${QT_INCLUDE_DIR}
is added to the include dirs given to moc.
Alex
|
|/
|
|
|
|
|
|
|
|
| |
This patch sets the FOLDER target property for the automoc target
to the same value as of the actual target. This organizes the targets
in IDEs with folders better.
Inspired-by: Mike Gelfand
Alex
|
|
|
|
|
|
|
|
|
| |
Now automoc always uses GetRealPath() so symbolic links are always
resolved and it doesn't end up with twice the same file, once with the real
path and once with the symlinked path in some setups where the source dir
can be accessed directly and via a symlink
Alex
|
|
|
|
|
| |
Also, no need to get the include directories from the target
beforehand. The local generator does that for us anyway.
|
|
|
|
| |
Alex
|
|
|
|
|
|
|
| |
The docs say that this is for cmake 2.4 backwards compatibility only,
so we probably don't need to support it.
Alex
|
|
|
|
| |
Alex
|
|
|
|
|
|
|
|
| |
Until now it was only rerun if the compile definitions changed, but
of course it also has to rerun if the include dirs or moc options
change. Strange that I didn't notice this before...
Alex
|
|
|
|
|
|
|
| |
automoc now fails immediately if moc fails, instead of continuing
and letting the build fail later on.
Alex
|
|
|
|
|
|
|
|
|
| |
Older C++ compilers do not provide a standard std::stringstream.
Use our compatibility interfaces instead.
Also avoid std::stringstream(openmode) signature. Our approximate
stringstream implementation provided when the standard one is not
available does not support the openmode argument.
|
| |
|
|
|
|
|
|
|
|
|
|
| |
The variables stored in the AutomocInfo.cmake file were not properly
escaped, so when reading them back they could turn into lists, if they
contained double quotes initially.
This patch fixes this by using cmLocalGenerator::EscapeForCMake() to
escape the variables properly.
Alex
|
|
|
|
| |
Alex
|
|
|
|
|
|
|
|
|
| |
automoc now defaults to strict mode, also with Qt4, i.e. it behaves as
the documentation says by default. I also inverted the switch
CMAKE_AUTOMOC_STRICT_MODE to CMAKE_AUTOMOC_RELAXED_MODE.
Docs and test adapted accordingly.
Alex
|
|\
| |
| |
| |
| | |
Conflicts:
Source/cmTarget.cxx
|
| |
| |
| |
| | |
There is no separate SrcTools module anymore.
|
| |\ |
|
| | |\
| | | |
| | | |
| | | |
| | | | |
83d02ee make automoc work when using ccmake via PATH (#12551)
|
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | | |
In ccmake, cmake::GetCMakeCommand() returns "/cmake" when ccmake
was started from the PATH, i.e. by simply running "ccmake"
Alex
|
| | |\ \
| | | | |
| | | | |
| | | | |
| | | | |
| | | | | |
2c648ab add documentation for the AUTOMOC_MOC_OPTIONS property
52719a1 automoc: fix #12541, support moc options
|
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | | |
This commit adds a new target property AUTOMOC_MOC_OPTIONS, which
can be set to add extra options for the moc invocations done via automoc.
This is equivalent to the OPTIONS parameter in the qt4_wrap_cpp() macro.
Alex
|
| | |\ \ \
| | | |/ /
| | | | |
| | | | |
| | | | |
| | | | | |
1ecc55a Automoc: fix the fix, need to use std::string, not just char* pointer
8c8305f don't crash in automoc with empty COMPILE_DEFINITIONS property
|
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | | |
We need to take a copy of the property values, since the returned
char* pointer is reused by the following GetProperty() calls
Alex
|
| | | |/
| | | |
| | | |
| | | |
| | | |
| | | |
| | | | |
Reported by Laszlo Papp:
http://www.cmake.org/pipermail/cmake/2011-October/047089.html
Alex
|
| | | | |
|
| | | | |
|
| |/ /
| | |
| | |
| | | |
Also handle Qt5SrcTools_MAJOR_VERSION.
|
| |/
| |
| |
| | |
The method of running moc hasn't changed in Qt5.
|
| |
| |
| |
| | |
Alex
|
| |
| |
| |
| | |
Alex
|
| |
| |
| |
| | |
Alex
|
| |
| |
| |
| | |
Alex
|
| |
| |
| |
| |
| |
| |
| |
| | |
ParseCppFile() is the one which is automoc4/KDE4-compatible, and which
becomes a bit crowded. By separating these two it is easier to ensure
that the strict one doesn't get broken accidentially.
Alex
|
| |
| |
| |
| | |
Alex
|
| |
| |
| |
| | |
Alex
|
| |
| |
| |
| | |
Alex
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
This is again for KDE4 compatiblity. If foo.moc is included, in general
moc should run on foo.cpp. Usually this can't cause problems.
It can only cause problems if moc must run on the header, and the resulting
file must be included in the cpp file, which is the case with the
Q_PRIVATE_SLOT macro.
This makes the test added by Stephen pass.
Alex
|
| |
| |
| |
| | |
Alex
|
| |
| |
| |
| | |
Alex
|
| |
| |
| |
| |
| |
| |
| |
| | |
-enable the KDE4-compatiblity mode only when using Qt4
-always (except in the KDE4 compat mode) error out if a cpp-file
contains "Q_OBJECT", but does not include filename.moc
Alex
|
| |
| |
| |
| |
| |
| |
| | |
before doing the full regexp, try a simple strstr(), if this
already fails, no need to do the regexp matching.
Alex
|
| |
| |
| |
| |
| |
| |
| |
| | |
Handing th std::string instead the char* to the find()
reduces the time from 17 to 15 seconds (for a 1000 times loop of a
relatively small file), which is around 10 percent.
Alex
|
| |
| |
| |
| |
| |
| |
| | |
Error/warning messages now look like:
AUTOMOC: (error|warning): <filename>: the actual text...
Alex
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
There are multiple/many places in KDE where the developer includes
moc_foo.cpp, and expects moc to run on foo.cpp, instead of foo.h.
He should use foo.moc, but right now this is handled by automoc4,
so we must stay compatible. So support this too, but warn about
it.
Alex
|
| |
| |
| |
| | |
Alex
|
|/
|
|
|
|
| |
foo.cpp must include foo.moc to have itself processed by moc
Alex
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This makes automoc behaves as the documentation says.
If there is a #include "foo.moc" in the source file, moc
will be executed on foo.cpp.
Before it was also executed on foo.cpp, but only if foo.cpp
contained a Q_OBJECT macro, otherwise moc was executed on
foo.h. This was confusing, and this change also shouldn't break
anything, since the headers are moc'ed anyway if they contain
a Q_OBJECT macro.
Alex
|
|
|
|
| |
Alex
|