summaryrefslogtreecommitdiffstats
path: root/Source
Commit message (Collapse)AuthorAgeFilesLines
* CMake 3.28.4v3.28.4Brad King2024-03-201-1/+1
|
* Ninja: Fix Fortran module deps in files INCLUDEd by preprocessed sourcesBrad King2024-03-192-9/+27
| | | | | | | If a preprocessed source also uses the Fortran `INCLUDE` directive, search the original source file's directory. Fixes: #25792
* cmQtAutoGenInitializer: De-duplicate autogen/timestamp target depend logicBrad King2024-03-141-24/+10
| | | | | | We place the same target ordering dependencies on either the `_autogen_timestamp_deps` target or the `_autogen` target. Refactor the logic to avoid duplicating that code.
* Autogen: Restore target-ordering dependencies in Makefiles with DEPFILEBrad King2024-03-141-15/+7
| | | | | | | | | | | | | | | | | | In commit aebfbcaa46 (AutoGen: Use depfiles for the XXX_autogen ninja targets, 2020-01-14, v3.17.0-rc1~58^2) the `_autogen_timestamp_deps` target was given target ordering dependencies through its custom command rather than direct target dependencies as on the `_autogen` target. Then commit 895fa3433f (cmQtAutoGenInitializer: support IMPLIB-only imported targets, 2021-09-23, v3.22.0-rc1~80^2) converted some target-level dependencies into file-level dependencies on the custom command. This only works with a monolithic build graph like Ninja. Since commit ebc9e448b3 (Autogen: Add depfile support for Makefiles, 2023-09-07, v3.28.0-rc1~101^2~1) we use the `_autogen_timestamp_deps` target in Makefile generators too. This exposed the missing target ordering dependency. Fixes: #25766
* cmImportedCxxModuleInfo: remove unused pointer fieldBen Boeckel2024-03-012-3/+1
| | | | | Also avoids usage of an invalid `importit` when module names are not available.
* cmExportFileGenerator: only export include paths for HEADERS file setsBen Boeckel2024-02-281-1/+4
|
* cmGeneratorTarget: collapse paths before querying the fileset cacheBen Boeckel2024-02-241-1/+2
| | | | | | Observed with paths with `../` when outside of the source tree. I attempted to reproduce a test suite case for it but could not make it happen.
* Restore support for TARGET_OBJECTS in link interfaces with unity buildsBrad King2024-02-213-6/+8
| | | | | | | | | | | | | This was broken by commit df08c37a42 (cmGlobalGenerator: Add unity/pch sources after computing compile features, 2024-02-02, v3.28.3~1^2~1^2), and 3.28.2's commit 76b5383123 (cmGlobalGenerator: add unity sources after computing target compile features, 2024-01-01, v3.28.2~17^2~1). The problem is very similar to that fixed by commit 4e8f24e977 (PCH: Clear link interface cache when adding PCH object to it, 2022-01-24, v3.23.0-rc1~44^2~9). Generalize that fix. Fixes: #25696
* cmGeneratorTarget: discover synthetic targets recursivelyBen Boeckel2024-02-201-0/+1
| | | | Fixes: #25288
* cmExportFileGenerator: export link libraries as-isBen Boeckel2024-02-201-5/+1
| | | | | | | This allows for transitive modules to work because `$<COMPILE_ONLY>`-wrapped dependencies do not end up in the `linked-target-dirs` collator property. Test suite exported property tests updated to account for the change.
* cmTarget: copy link libraries from the right propertiesBen Boeckel2024-02-191-1/+1
| | | | | | | This fixes transitive dependencies' usage requirements not appearing when compiling synthetic targets. See: https://discourse.cmake.org/t/9819
* cmGeneratorTarget: store synthetic targets in its cacheBen Boeckel2024-02-161-0/+1
| | | | | | | The synthetic target cache was never actually updated, so record them in the cache so that reuses can actually be discovered. Fixes: #25568
* Merge topic 'cxxmodules-dyndep-error-on-private-usage' into release-3.28Brad King2024-02-163-3/+10
|\ | | | | | | | | | | | | 3f8a59a05c cxxmodules: return failure from the collator when private usage is found Acked-by: Kitware Robot <kwrobot@kitware.com> Merge-request: !9257
| * cxxmodules: return failure from the collator when private usage is foundBen Boeckel2024-02-153-3/+10
| |
* | Merge topic 'cxxmodules-collation-restat' into release-3.28Brad King2024-02-162-0/+7
|\ \ | | | | | | | | | | | | | | | | | | | | | a7424b636b Ninja: make the collator rule use `restat = 1` e24eecfc33 Tests/CXXModules: add a test to ensure that `restat` works for collation Acked-by: Kitware Robot <kwrobot@kitware.com> Merge-request: !9259
| * | Ninja: make the collator rule use `restat = 1`Ben Boeckel2024-02-152-0/+7
| | | | | | | | | | | | This avoids rebuilds when the module metadata does not change.
* | | Merge topic 'cxxmodules-visibility-change-rebuild' into release-3.28Brad King2024-02-161-3/+7
|\ \ \ | |/ / | | | | | | | | | | | | | | | | | | | | | 60a8736378 cmNinjaTargetGenerator: scanning depends on the module metadata 52036ce090 Tests/CXXModules: test that objects depend on dependent modules json files 9a45c9fbd5 cmNinjaTargetGenerator: use `emplace_back` for scanning deps Acked-by: Kitware Robot <kwrobot@kitware.com> Merge-request: !9247
| * | cmNinjaTargetGenerator: scanning depends on the module metadataBen Boeckel2024-02-151-0/+2
| | | | | | | | | | | | Fixes: #25531
| * | cmNinjaTargetGenerator: use `emplace_back` for scanning depsBen Boeckel2024-02-151-3/+5
| | |
* | | Merge topic 'cxxmodules-depend-on-modmap-file' into release-3.28Brad King2024-02-161-1/+1
|\ \ \ | |/ / | | | | | | | | | | | | | | | | | | | | | 363300ace5 cxxmodules: depend on the modmap contents 940628d48d Tests/CXXModules: test that objects depend on their modmap files 681ee92030 Tests/CXXModules: support testing rebuild conditions Acked-by: Kitware Robot <kwrobot@kitware.com> Merge-request: !9248
| * | cxxmodules: depend on the modmap contentsBen Boeckel2024-02-151-1/+1
| |/ | | | | | | | | | | | | If the modmap changes, we need to recompile. It is not just a file that needs to exist to compile. Fixes: #25511
* | Merge topic 'cxxmodules-collapse-source-paths' into release-3.28Brad King2024-02-151-2/+3
|\ \ | | | | | | | | | | | | | | | | | | 0f0d853de7 cmDyndepCollation: collapse full path before looking up Acked-by: Kitware Robot <kwrobot@kitware.com> Merge-request: !9249
| * | cmDyndepCollation: collapse full path before looking upBen Boeckel2024-02-141-2/+3
| |/ | | | | | | | | | | | | | | `cmSourceFile::GetFullPath()` performs a `CollapseFullPath` before storing the path. Match this behavior when looking up paths from the source file set constructions. Fixes: #25614
* | visionOS: Update deployment-target flag for Xcode 15.1 betaBrad King2024-02-091-3/+36
| | | | | | | | | | | | | | | | Use the same flags Xcode adds for `XROS_DEPLOYMENT_TARGET`. They are `-target arm64-apple-xros1.0` and `-target arm64-apple-xros1.0-simulator`, where `1.0` is the deployment target version. Fixes: #25188
* | cmLocalGenerator: Avoid unnecessary lookup without a deployment targetBrad King2024-02-091-8/+10
| |
* | libuv: win/spawn: optionally run executable paths with no file extensionBrad King2024-02-081-1/+3
| | | | | | | | | | | | | | | | Backport libuv commit `3f7191e5` (win/spawn: optionally run executable paths with no file extension, 2024-02-05, v1.48.0~8) to add the `UV_PROCESS_WINDOWS_FILE_PATH_EXACT_NAME` option we now use. Issue: #25450
* | cmUVProcessChain: Implement no-extension-on-Windows support with libuv 1.48Brad King2024-02-081-0/+3
|/ | | | | Use the new `UV_PROCESS_WINDOWS_FILE_PATH_EXACT_NAME` option when building against libuv 1.48 or higher.
* CMake 3.28.3v3.28.3Brad King2024-02-051-1/+1
|
* Unity: Clarify source comments on unity build transformationBrad King2024-02-022-1/+3
|
* Merge branch 'unity-after-compile-features' into restore-pch-with-unityBrad King2024-02-022-29/+10
|\ | | | | | | | | | | | | | | | | | | Replace commit 76b5383123 (cmGlobalGenerator: add unity sources after computing target compile features, 2024-01-01, v3.28.2~17^2~1) with an alternative change. This merge commit resolves conflicts such that future `git blame` calls will follow the second parent for the relevant lines and pretend the replaced commit never existed. Fixes: #25650
| * cmGlobalGenerator: Add unity/pch sources after computing compile featuresBrad King2024-02-022-5/+15
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Sources that will be scanned for C++ module dependencies need to be excluded from unity builds. We need to compute compile features in order to know which sources will be scanned. Unity build and PCH sources can be added afterward without changing the compile features. This re-implements commit 76b5383123 (cmGlobalGenerator: add unity sources after computing target compile features, 2024-01-01, v3.28.2~17^2~1) using a simpler approach that also preserves support for PCH with Unity builds. Issue: #25650 Co-authored-by: Ben Boeckel <ben.boeckel@kitware.com>
* | CMake 3.28.2v3.28.2Brad King2024-01-291-1/+1
| |
* | Autogen: Forward dependencies when both Makefile and DEPFILE are usedOrkun Tokdemir2024-01-281-1/+10
| | | | | | | | | | | | | | | | | | | | | | | | Since commit ebc9e448b3 (Autogen: Add depfile support for Makefiles, 2023-09-07, v3.28.0-rc1~101^2~1) CMake does not generate the correct dependency graph when both `Makefile` and `DEPFILE` are used. The build of `<target_name>_autogen_timestamp_deps` fails due to missing dependencies. To tackle that problem, forward target dependencies to both `<target_name>_autogen_timestamp_deps` and `<target_name>_autogen` instead of just `<target_name>_autogen`. Fixes: #25600
* | cmQtAutoGenInitializer: Improve Const-correctnessOrkun Tokdemir2024-01-261-1/+1
| |
* | Revert use of libuv for process execution for 3.28Brad King2024-01-2431-1221/+1186
| | | | | | | | | | | | | | | | | | | | | | | | | | | | Wide use of CMake 3.28.{1,0[-rcN]} has uncovered some hangs and crashes in libuv SIGCHLD handling on some platforms, particularly in virtualization environments on macOS hosts. Although the bug does not seem to be in CMake, we can restore stability in the CMake 3.28 release series for users of such platforms by reverting our new uses of libuv for process execution. Revert implementation changes merged by commit 4771544386 (Merge topic 'replace-cmsysprocess-with-cmuvprocesschain', 2023-09-06, v3.28.0-rc1~138), but keep test suite updates. Issue: #25414, #25500, #25562, #25589
* | cmUVProcessChain: Tolerate fileno() of invalid FILE streamBrad King2024-01-241-1/+5
| | | | | | | | | | | | | | | | On Windows, in a GUI process without a console, the `std{in,out,err}` standard FILE streams may not be open. Avoid passing an invalid file descriptor to the child process, and let libuv attach NUL instead. Fixes: #25625
* | cmUVProcessChain: Simplify SetExternalStream usageBrad King2024-01-248-40/+26
| | | | | | | | | | It is commonly called with the `fileno()` of a `FILE*` stream, so accept the latter directly.
* | cmUVProcessChain: Simplify builder initializationBrad King2024-01-242-8/+3
| |
* | cxxmodules: make export trampoline script files uniqueBen Boeckel2024-01-188-27/+55
| | | | | | | | | | | | | | | | | | | | | | Include the name of the `EXPORT` in the filename when generating export information for C++ modules. This allows the same directory to be used for multiple sets of C++ module-using targets. For `export(TARGETS)` uses, generate a name based on the hash of the concatenation of the target names involved with the `export()` call. Fixes: #25609
* | Source: Simplify hasher object constructionBrad King2024-01-182-7/+6
| |
* | cxxmodules: compute link information for C++ module-consuming targetsMatheus Izvekov2024-01-141-1/+2
| | | | | | | | | | | | | | | | | | Compute link information for all C++ targets which support modules instead of just those which may provide modules, as they may import modules as well. This captures `OBJECT` libraries using modules which otherwise do not have link steps. Fixes: #25592
* | Merge topic 'vs-scan-for-modules' into release-3.28Brad King2024-01-101-5/+6
|\ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | 405dc7d19c Tests/CXXModules/scan_properties: use `ixx` extension 029ddc3410 cmVisualStudio10TargetGenerator: always specify scanning 6c9614cbf4 Tests/CXXModules: add a test case for VS generation without flags 34f4423851 cmVisualStudio10TargetGenerator: fix typo in flag name Acked-by: Kitware Robot <kwrobot@kitware.com> Merge-request: !9104
| * | cmVisualStudio10TargetGenerator: always specify scanningBen Boeckel2024-01-061-3/+4
| | | | | | | | | | | | | | | | | | | | | Set that sources should not be scanned on a target-wide basis and then enable on a per-TU basis as needed. Fixes: #25519
| * | cmVisualStudio10TargetGenerator: fix typo in flag nameBen Boeckel2024-01-061-3/+3
| |/ | | | | | | | | It is case insensitive, so this only matches the official flag name and still works.
* | Merge topic 'cxxmodules-no-unity' into release-3.28Brad King2024-01-103-1/+39
|\ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | 63bbb3768d cmLocalGenerator: ignore scanned sources for unity builds 76b5383123 cmGlobalGenerator: add unity sources after computing target compile features 7fc2a83fe6 Tests/CXXModules: add a test with unity build support Acked-by: Kitware Robot <kwrobot@kitware.com> Acked-by: buildbot <buildbot@kitware.com> Merge-request: !9118
| * | cmLocalGenerator: ignore scanned sources for unity buildsBen Boeckel2024-01-051-0/+9
| | |
| * | cmGlobalGenerator: add unity sources after computing target compile featuresBen Boeckel2024-01-052-1/+30
| |/ | | | | | | | | | | We need to know which sources will be scanned for C++ module dependencies in order to exclude them from unity builds. The addition of unity sources will not change the set of features.
* | Makefile: Fix double escaping when DEPFILE is usedOrkun Tokdemir2024-01-091-3/+2
| | | | | | | | | | | | | | | | | | | | In commit cfd8a5ac1f (Makefiles: Add support of DEPFILE for add_custom_command, 2020-12-04, v3.20.0-rc1~237^2~1) we added a `ConvertToOutputPath` call on a path given to the `depends` field of `WriteMakeRule`. The latter already handles escaping for Makefile syntax. Fixes: #25554
* | Makefile: Reduce string copiesOrkun Tokdemir2024-01-081-1/+1
| |
* | Source: Restore compilation on OpenBSDRafael Sadowski2024-01-053-7/+7
|/ | | | We cannot use `OpenBSD` as a name, it is defined in `sys/param.h`.