summaryrefslogtreecommitdiffstats
path: root/Source/cmQtAutoGeneratorMocUic.cxx
Commit message (Collapse)AuthorAgeFilesLines
* Autogen: Fix deadlock when uv_spawn() fails while trying to run mocAlexandru Croitor2019-03-251-1/+5
| | | | | | | | | | | | If by some chance the moc executable does not exist while running AUTOMOC, instead of showing an error, the CMake Autogen invocation hangs indefinitely. This happens because UVProcessFinished() is not called if the process does not launch correctly. Make sure to call UVProcessFinished() even if the process launch fails, and also report the error returned by libuv.
* Replace use of CollapseCombinedPath with CollapseFullPathBrad King2019-03-191-1/+1
| | | | | | | | | | | `CollapseCombinedPath` was introduced by commit 551d3343cd (cmDependsC: Collapse relative include paths, 2013-06-19, v2.8.12~237^2) where the existing `CollapseFullPath` should have been used instead. Then its use proliferated slightly. Since `CollapseCombinedPath` is less widely used and less robust (see issue #19049), use `CollapseFullPath` everywhere instead. Issue: #19050
* Autogen: Move additional source header search to configuration stageSebastian Holtermann2019-02-251-29/+4
| | | | | | | | The computation of additional source headers and and private headers for AUTOGEN is moved from the _autogen target to the configuration stage. This makes them available for _autogen target dependency computations. Closes: #18949
* Autogen: Refactor file lists computationSebastian Holtermann2019-02-251-48/+61
| | | | | | | In AUTOGEN this replaces simple file name lists with two list (for headers and sources) of structs with file name and file flags. The file name lists that are passed to the _autogen target via AutogenInfo.cmake are filtered from these two lists.
* Autogen: Use cm::make_unique to allocate jobsSebastian Holtermann2019-02-221-17/+12
|
* Autogen: Rename cmQtAutoGen::GeneratorT enum to cmQtAutoGen::GenTSebastian Holtermann2019-02-211-69/+64
|
* Remove return from void functionAlbert Astals Cid2019-02-141-3/+3
|
* Autogen: AUTOMOC support for files with the same name but different extensionsSebastian Holtermann2019-02-051-12/+34
| | | | | | | | | This adds support for AUTOMOC to moc header files with the same but different extensions (e.g `obj.h`, `obj.hpp`, `obj.hxx`). If a moc file would appear multiple times in `mocs_compilation.cpp`, a number suffix is appended to the name to make it unique. Closes #14489
* Autogen: Refactor std::bind calls to lambdasArtur Ryt2019-01-291-2/+1
|
* clang-tidy: Use `= default`Regina Pfeifer2019-01-251-3/+1
| | | | | | Suppress some cases in `Source/cmGeneratorExpressionNode.cxx` and `Source/cmUVHandlePtr.h` where a few older compilers require a user-defined default constructor (with `{}`).
* Merge topic 'read-list-file'Brad King2019-01-211-1/+1
|\ | | | | | | | | | | | | 25caf7bafe cmMakefile::ReadListFile() accepts std::string argument Acked-by: Kitware Robot <kwrobot@kitware.com> Merge-request: !2821
| * cmMakefile::ReadListFile() accepts std::string argumentVitaly Stakhovsky2019-01-171-1/+1
| | | | | | | | Same for cmMakefile::ReadDependentFile(); some cleanup
* | clang-tidy: Use emplaceRegina Pfeifer2019-01-171-5/+5
|/
* IWYU: Update CMake code for IWYU built with Clang 6Brad King2019-01-151-1/+3
| | | | | IWYU now correctly requires `<utility>` for `std::move`. It also requires a container header when used via a range-based for loop.
* clang-tidy: Use default member initializationRegina Pfeifer2018-12-151-5/+0
|
* Autogen: Don't add a WIN32 moc definition if we have a moc_predefs.h fileSebastian Holtermann2018-11-281-10/+0
| | | | | | | | On Windows systems we used to add a "-DWIN32" definition to the ``moc`` defines. This is not necessary anymore when we have a ``moc_predefs.h`` file that provides all compiler predefines. Closes #18623
* cmMakefile: Make GetSafeDefinition return std::string const&Vitaly Stakhovsky2018-09-181-3/+4
|
* Autogen: Pass absolute include path in info fileSebastian Holtermann2018-07-301-8/+5
|
* Autogen: Add CMAKE_AUTOGEN_VERBOSE variable supportSebastian Holtermann2018-06-211-0/+1
| | | | | Setting CMAKE_AUTOGEN_VERBOSE enables verbose output during AUTOMOC, AUTOUIC and AUTORCC generation.
* Revise C++ coding style using clang-format-6.0Kitware Robot2018-06-011-4/+5
| | | | | | | | | | | | Run the `clang-format.bash` script to update all our C and C++ code to a new style defined by `.clang-format`. Use `clang-format` version 6.0. * If you reached this commit for a line in `git blame`, re-run the blame operation starting at the parent of this commit to see older history for the content. * See the parent commit for instructions to rebase a change across this style transition commit.
* Cleanup: Fix typos and grammar in docs and codeCraig Scott2018-04-221-2/+2
| | | No functional changes, just docs, comments and error messages.
* Merge topic 'autogen-protect-cmsys-calls'Brad King2018-04-041-22/+30
|\ | | | | | | | | | | | | | | | | | | | | | | | | b11e2c80b1 Autogen: Print moc/uic/rcc output to stdout 1d2c9d8c6d Autogen: Use std::istreambuf_iterator for file so string reading ccc38fa509 Autogen: Protected calls to cmFilePathChecksum 719b24c872 Autogen: Protected calls to cmQtAutoGen::SubDirPrefix 9a73615815 Autogen: Protected calls to cmSystemTools::GetFilenameWithoutLastExtension 65203ce407 Autogen: Protected calls to cmSystemTools::Split/JoinPath 14a86c9ea7 Autogen: Protected calls to cmSystemTools::CollapseCombinedPath Acked-by: Kitware Robot <kwrobot@kitware.com> Merge-request: !1918
| * Autogen: Print moc/uic/rcc output to stdoutSebastian Holtermann2018-04-031-3/+11
| | | | | | | | | | | | | | | | The output of moc/uic/rcc used to be discarded unless the program failed. This lets moc/uic/rcc print their output to stdout even on success. Closes #17860
| * Autogen: Protected calls to cmFilePathChecksumSebastian Holtermann2018-04-031-2/+2
| | | | | | | | | | Closes #17861 Closes #17862
| * Autogen: Protected calls to cmQtAutoGen::SubDirPrefixSebastian Holtermann2018-04-031-5/+5
| |
| * Autogen: Protected calls to cmSystemTools::GetFilenameWithoutLastExtensionSebastian Holtermann2018-04-031-5/+5
| |
| * Autogen: Protected calls to cmSystemTools::Split/JoinPathSebastian Holtermann2018-04-031-2/+2
| |
| * Autogen: Protected calls to cmSystemTools::CollapseCombinedPathSebastian Holtermann2018-04-031-5/+5
| |
* | MAINT: Misc. typosluz.paz2018-02-131-3/+3
|/ | | | Found via `codespell -q 3 -I ../cmake-whitelist.txt`.
* Autogen: Improved multi-config include schemeSebastian Holtermann2018-02-021-50/+54
| | | | | | | | | | | | | | | | | | | | | | | | | For multi configuration generators AUTOMOC generates the moc files that are included in `mocs_compilation.cpp` in `AUTOGEN_BUILD_DIR/include_$<CONFIG>/`. By doing so each configuration reads different moc files when compiling `mocs_compilation.cpp`. Since we do not (need to) rewrite `mocs_compilation.cpp` on a configuration change anymore, the files also does not need to be recompiled anymore. Not having to rewrite and recompile `mocs_compilation.cpp` on a configuration change anymore was the main objective of this patch. In a similar fashion AUTORCC generates a `qrc_BASE_CMAKE.cpp` file below `AUTOGEN_BUILD_DIR/include_$<CONFIG>/` and `qrc_BASE.cpp` becomes a mere wrapper that includes this actuall rcc output file (when using multi configuration generators). The template files `Modules/AutoRccInfo.cmake.in` and `Modules/AutogenInfo.cmake.in` were removed in favor of writing the info `.cmake` files manually. Closes #17230
* Autogen: AUTOMOC/UIC fix for moc/uic include on the first lineSebastian Holtermann2018-01-181-4/+4
| | | | | | | | When moc/uic include was found on the first line of a file it was ignored. This fixes the issue by extending the regular expression for include detection. Closes #17655
* Autogen: Process files concurrently in AUTOMOC and AUTOUICSebastian Holtermann2018-01-171-1369/+1660
| | | | | | | | | | | | | | | | | | | | | | This introduces concurrent thread processing in the `_autogen` target wich processes AUTOMOC and AUTOUIC. Source file parsing is distributed among the threads by using a job queue from which the threads pull new parse jobs. Each thread might start an independent ``moc`` or ``uic`` process. Altogether this roughly speeds up the AUTOMOC and AUTOUIC build process by the number of physical CPUs on the host system. The exact number of threads to start in the `_autogen` target is controlled by the new AUTOGEN_PARALLEL target property which is initialized by the new CMAKE_AUTOGEN_PARALLEL variable. If AUTOGEN_PARALLEL is empty or unset (which is the default) the thread count is set to the number of physical CPUs on the host system. The AUTOMOC/AUTOUIC generator and the AUTORCC generator are refactored to use a libuv loop internally. Closes #17422.
* Various typo fixesLuz Paz2018-01-031-1/+1
| | | | Some are user-facing. Others are source comments.
* Autogen: Use integers instead of strings for the Qt versionSebastian Holtermann2017-11-191-12/+7
|
* Autogen: Make cmQtAutoGeneratorInitializer an instantiable classSebastian Holtermann2017-11-191-7/+2
| | | | | Remove the cmQtAutoGenDigest classes and make cmQtAutoGeneratorInitializer instantiable instead.
* Autogen: Add and use cmQtAutoGenerator base classSebastian Holtermann2017-11-191-357/+55
| | | | | | Adds the new base class `cmQtAutoGenerator` which contains common variables and methods used by `cmQtAutoGeneratorMocUic` and `cmQtAutoGeneratorRcc`.
* Autogen: Rename cmQtAutoGenerators to cmQtAutoGeneratorMocUicSebastian Holtermann2017-11-191-0/+2045