https://github.com/Kitware/CMake
Revision d592bfc9f5f616249d85bbea94d8e76a666591a8 authored by Sebastian Holtermann on 10 January 2018, 14:17:02 UTC, committed by Sebastian Holtermann on 10 January 2018, 18:46:22 UTC
Until CMake 3.10 a list of source files that had the AUTOUIC_OPTIONS property
populated was kept in `cmMakefile::QtUiFilesWithOptions`.  In the process to
remove all AUTOUIC related code from `cmMakefile` for CMake 3.10, the pre
filtered list was replaced by a loop in `cmQtAutoGeneratorInitializer` over
all source files in the `cmMakefile`.  This loop introduced the problem that
file paths were computed for source files that weren't in the target's sources
and that might not even have existed.  If the path for an unused and not
existing file was computed a `cmake::FATAL_ERROR` with the error message
"Cannot find source file:" was thrown nevertheless.
This caused some projects to fail in CMake 3.10.

This patch adds a test for path errors in the loops in
`cmQtAutoGeneratorInitializer` that iterate over all source files in a
`cmMakefile`. If a path error appears, the file is silently ignored.
If the file is part of the target's sources, the path error will still be
caught in the loop over all the target's sources.

This is the fix for CMake 3.10.1.
1 parent 166bf4c
History
Tip revision: d592bfc9f5f616249d85bbea94d8e76a666591a8 authored by Sebastian Holtermann on 10 January 2018, 14:17:02 UTC
Autogen: Ignore not existing source files in cmMakefile
Tip revision: d592bfc
File Mode Size
.github
Auxiliary
Help
Licenses
Modules
Packaging
Source
Templates
Tests
Utilities
.clang-format -rw-r--r-- 201 bytes
.clang-tidy -rw-r--r-- 969 bytes
.gitattributes -rw-r--r-- 1.1 KB
.gitignore -rw-r--r-- 64 bytes
.hooks-config -rw-r--r-- 418 bytes
CMakeCPack.cmake -rw-r--r-- 9.8 KB
CMakeCPackOptions.cmake.in -rw-r--r-- 12.4 KB
CMakeGraphVizOptions.cmake -rw-r--r-- 153 bytes
CMakeLists.txt -rw-r--r-- 29.7 KB
CMakeLogo.gif -rw-r--r-- 4.4 KB
CONTRIBUTING.rst -rw-r--r-- 2.1 KB
CTestConfig.cmake -rw-r--r-- 440 bytes
CTestCustom.cmake.in -rw-r--r-- 6.2 KB
CompileFlags.cmake -rw-r--r-- 2.6 KB
Copyright.txt -rw-r--r-- 5.0 KB
DartConfig.cmake -rw-r--r-- 374 bytes
README.rst -rw-r--r-- 3.0 KB
bootstrap -rwxr-xr-x 47.2 KB
cmake_uninstall.cmake.in -rw-r--r-- 790 bytes
configure -rwxr-xr-x 99 bytes
doxygen.config -rw-r--r-- 27.4 KB

README.rst

back to top