summaryrefslogtreecommitdiffstats
path: root/Source/cmQtAutoGenInitializer.h
Commit message (Collapse)AuthorAgeFilesLines
* AutoRcc: Use cmQtAutoGen::RccLister in initializer and generatorSebastian Holtermann2019-04-061-4/+0
| | | | | | | Both classes `cmQtAutoGenInitializer` and `cmQtAutoGeneratorRcc` had different implementations for reading the files list from a `.qrc` resources file. This patch replaces both implementations with the common simple `cmQtAutoGen::RccLister` implementation.
* Autogen: Remove lowercase generator name from generator variables classSebastian Holtermann2019-04-021-11/+5
| | | | | The lowercase `Auto*` generator name in `cmQtAutoGenInitializer::GenVarsT` is never user. Remove it from the class.
* Autogen: Fallback on internal qrc parser when RCC isn't built yetAlexandru Croitor2019-03-041-0/+1
| | | | | | | | | | | When building a Qt project, the AUTORCC functionality, by default, uses the rcc binary to get the contents of a qrc file for dependency information. This is done at CMake "generate" time. The problem is that while configuring Qt itself, the rcc binary is not built yet. In that case, to get the contents of the qrc file, fall back to the code branch which uses an ifstream instead of the rcc binary.
* Autogen: Use more readable variable names for static const AUTO* stringsSebastian Holtermann2019-02-261-6/+6
|
* Autogen: Refactor file lists computationSebastian Holtermann2019-02-251-6/+28
| | | | | | | 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: Refactor cmQtAutoGenInitializer::AddGeneratedSource methodSebastian Holtermann2019-02-211-1/+4
| | | | | In AUTOGEN pass the abstract cmQtAutoGenInitializer::GenVarsT to methods to identify the generator (moc/uic/rcc).
* Autogen: Refactor Qt executable name computationSebastian Holtermann2019-02-211-17/+42
| | | | | | In AUTOGEN a common new base class cmQtAutoGenInitializer::GenVarsT for mo/uic/rcc generator variables allows to generalize variable computation functions.
* Autogen: Rename cmQtAutoGen::GeneratorT enum to cmQtAutoGen::GenTSebastian Holtermann2019-02-211-1/+1
|
* Autogen: Use output caching GetExecutableTestOutputSebastian Holtermann2019-02-191-0/+4
| | | | | | | Use the output caching cmQtAutoGenGlobalInitializer::GetExecutableTestOutput method to avoid identical calls to moc, uic and rcc. Closes #18947
* cleanup: Prefer compiler provided special member functionsRegina Pfeifer2019-01-251-3/+0
|
* clang-tidy: Use `= default`Regina Pfeifer2019-01-251-1/+1
| | | | | | Suppress some cases in `Source/cmGeneratorExpressionNode.cxx` and `Source/cmUVHandlePtr.h` where a few older compilers require a user-defined default constructor (with `{}`).
* Autogen: Prepend instead of append `mocs_compilation.cpp` to the sources listSebastian Holtermann2019-01-181-1/+2
| | | | | | | | | | | | | | `mocs_compilation.cpp` easily takes a long time to compile when it contains multiple `moc` files. When it was appended like before we ran into the situation that all smaller sources were already compiled when `mocs_compilation.cpp` got compiled at last. In that case a single core was busy but all remaining cores stayed idle. To optimize CPU core utilization we now prepend `mocs_compilation.cpp` to the sources list instead of appending it. This allows smaller source files to get compiled *while* the long lasting `mocs_compilation.cpp` gets compiled. Closes #18793
* Autogen: Adaptive missing Qt warningSebastian Holtermann2019-01-151-1/+4
| | | | | This makes the warning message for a missing Qt use the requested Qt version in the message text.
* clang-tidy: Use default member initializationRegina Pfeifer2018-12-151-7/+3
|
* Mark operator bool explicitRegina Pfeifer2018-11-191-1/+1
|
* Autogen: Add and use cmQtAutoGenInitializer::InfoWriter classSebastian Holtermann2018-11-141-6/+41
| | | | | | | | | The new ``cmQtAutoGenInitializer::InfoWriter`` class provides an interface to write strings/vectors/sets/maps in CMake format into a file. Its use replaces various `cmJoin` calls that failed to address escaping of semicolons in list elements. Closes #18554
* Autogen: Add support for global ``autogen`` and ``autorcc`` targetsSebastian Holtermann2018-11-111-2/+8
| | | | | | | | | | | | | | This teaches CMake the variables - CMAKE_GLOBAL_AUTOGEN_TARGET - CMAKE_GLOBAL_AUTOGEN_TARGET_NAME - CMAKE_GLOBAL_AUTORCC_TARGET - CMAKE_GLOBAL_AUTORCC_TARGET_NAME which control the generation of global ``autogen`` and ``autorcc`` targets. Closes #17721
* Autogen: Add (CMAKE_)AUTOGEN_ORIGIN_DEPENDS supportSebastian Holtermann2018-11-031-0/+1
| | | | | | | | | | | | | | | This adds - the variable ``CMAKE_AUTOGEN_ORIGIN_DEPENDS`` which initializes - the target property ``AUTOGEN_ORIGIN_DEPENDS`` which controls whether or not the origin target dependencies should be forwarded to the corresponding ``_autogen`` target. The default value of ``CMAKE_AUTOGEN_ORIGIN_DEPENDS`` is ``ON`` which corresponds to the behavior that is in place since CMake 3.9. Closes: #18493
* Autogen: Use integers to store the Qt versionSebastian Holtermann2018-08-131-12/+4
|
* Autogen: Initializer: Group variables in structsSebastian Holtermann2018-08-131-23/+35
|
* Autogen: Split initializer main methodSebastian Holtermann2018-07-301-6/+21
|
* Autogen: Compute variables in Init stage instead of Setup stageSebastian Holtermann2018-07-301-6/+8
|
* Autogen: Move info file write code into methodsSebastian Holtermann2018-07-301-0/+3
|
* Autogen: Pass absolute include path in info fileSebastian Holtermann2018-07-301-0/+2
|
* Autogen: Wrap moc/uic/rcc related variables in structsSebastian Holtermann2018-07-111-20/+29
|
* Autogen: Improve error detection during configurationSebastian Holtermann2018-07-111-4/+8
| | | | | | | | | | | | | | cmQtAutoGenInitializer::InitCustomTargets and cmQtAutoGenInitializer::SetupCustomTargets now return their success value which gets evaluated and passed on by the caller (cmGlobalGenerator). Checks for the existance of the moc/uic/rcc binaries have been introduces in cmQtAutoGenInitializer. Additionally they get called once with a "-h" argument to determine if they're functional. This way any binary-not-found problem is caught during the configuration phase.
* 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.
* Autogen: Add lock file to AUTORCC commandsSebastian Holtermann2018-05-301-0/+1
| | | | | By using a per .qrc lock file in AUTORCC, the same `cmake -E cmake_autorcc ...` command can be called concurrently.
* Autogen: Improved multi-config include schemeSebastian Holtermann2018-02-021-6/+19
| | | | | | | | | | | | | | | | | | | | | | | | | 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: Rename cmQtAutogeneratorInitializer to cmQtAutoGenInitializerSebastian Holtermann2018-01-171-0/+102