summaryrefslogtreecommitdiffstats
path: root/Source/cmGeneratorTarget.cxx
Commit message (Collapse)AuthorAgeFilesLines
* VERIFY_INTERFACE_HEADER_SETS: Skip header files that have SKIP_LINTINGKyle Edwards2023-06-061-0/+4
| | | | Fixes: #24972
* cxxmodules: remove `CMAKE_EXPERIMENTAL_CXX_MODULE_DYNDEP` variableBen Boeckel2023-06-011-1/+3
| | | | It is now subsumed by the UUID setting completely.
* Merge topic 'remove-header-unit-fileset-type'Brad King2023-06-011-19/+6
|\ | | | | | | | | | | | | | | | | 7b62a83c6f cxxmodules: update the experimental UUID 6ff5cdc533 cxxmodules: remove support for `CXX_MODULE_HEADER_UNITS` filesets Acked-by: Kitware Robot <kwrobot@kitware.com> Acked-by: buildbot <buildbot@kitware.com> Merge-request: !8510
| * cxxmodules: remove support for `CXX_MODULE_HEADER_UNITS` filesetsBen Boeckel2023-05-311-19/+6
| | | | | | | | | | There's no backing implementation for header units anyways, so just remove it for now.
* | CUDA/NVIDIA: fix LTO with explicit architecturesRafael Stahl2023-05-311-1/+1
|/
* Apple Framework: enhance path parsingMarc Chevrier2023-05-211-14/+8
|
* Apple Frameworks: honor SYSTEM target propertyMarc Chevrier2023-05-111-13/+28
| | | | Fixes: #24109
* Merge topic 'compile-only-genex'Brad King2023-05-051-1/+3
|\ | | | | | | | | | | | | | | | | c42630ee62 cmGeneratorExpressionNode: implement `COMPILE_ONLY` genex 0fb923c460 cmGeneratorExpressionNode: implement `COMPILE_ONLY` genex Acked-by: Kitware Robot <kwrobot@kitware.com> Tested-by: buildbot <buildbot@kitware.com> Merge-request: !8411
| * cmGeneratorExpressionNode: implement `COMPILE_ONLY` genexRobert Maynard2023-05-041-1/+3
| | | | | | | | | | | | | | | | | | This generator expression is the inverse of `LINK_ONLY` and only coveys usage requirements for the purposes of compilation. Its intended use is to avoid needing to export targets that do not have link usage requirements (e.g., header-only libraries) when used by another target. See: #15415
* | Merge topic 'use-linker-depfile'Brad King2023-05-041-0/+24
|\ \ | | | | | | | | | | | | | | | | | | | | | 375e6fdbbe Link step: use linker dependency linker file 24a3e5cda0 cmLocalGenerator::MayBeRelativeToWorkDir: take care of all cases Acked-by: Kitware Robot <kwrobot@kitware.com> Merge-request: !8443
| * | Link step: use linker dependency linker fileMarc Chevrier2023-05-031-0/+24
| | | | | | | | | | | | | | | | | | Based on work done by @ben.boeckel (!8051) Fixes: #22217
* | | Merge topic 'autogen-system-include'Brad King2023-05-041-0/+23
|\ \ \ | |/ / |/| | | | | | | | | | | | | | | | | | | | | | | 7bf4e30090 Autogen: Default AUTOGEN_USE_SYSTEM_INCLUDE to ON if it is not set 033dc7ee2f Autogen: Add AUTOGEN_USE_SYSTEM_INCLUDE target property 8ba16db163 Tests/RunCMake: Add option for dynamic expected output Acked-by: Kitware Robot <kwrobot@kitware.com> Acked-by: buildbot <buildbot@kitware.com> Merge-request: !8400
| * | Autogen: Add AUTOGEN_USE_SYSTEM_INCLUDE target propertyOrkun Tokdemir2023-05-031-0/+23
| | | | | | | | | | | | | | | | | | | | | `AUTOGEN_USE_SYSTEM_INCLUDE` was added. `AUTOGEN_USE_SYSTEM_INCLUDE` is a boolean property that can be set on a target to indicate that the autogen target include directory should be added as a system include directory or normal include directory to the target.
* | | CMake code rely on cmList class for CMake lists management (part. 2)Marc Chevrier2023-04-291-70/+45
|/ /
* | CMake code rely on cmList class for CMake lists management (part. 1)Marc Chevrier2023-04-241-30/+31
|/
* cmGeneratorTarget: Factor out EvaluatedTargetProperty infrastructureOrkun Tokdemir2023-04-051-189/+37
| | | | | Make it available outside the `cmGeneratorTarget` implementation. In particular, we will later use it in `cmQtAutoGenInitializer`.
* cmGeneratorTarget: Avoid incidental include-what-you-use warningBrad King2023-04-051-2/+2
| | | | Avoid `warning: Extra tokens on pragma line` from IWYU.
* CUDA: Fix CUDA architecture flags for nvcc response filesBrad King2023-03-301-2/+2
| | | | | | | | `nvcc --options-file` does not parse unquoted arguments in a response file correctly if they contain `[]`. Quote the `--generate-code=` flags we add for CUDA architectures. Fixes: #24657
* macOS: Suppress default '-arch arm64' with CMAKE_<LANG>_COMPILER_TARGETBrad King2023-03-151-2/+6
| | | | | | | | | | | | | Since commit b6c60f14b6 (macOS: Default to arm64 architecture on Apple Silicon hosts, 2020-09-28, v3.19.0-rc1~63^2) we add `-arch arm64` by default on Apple Silicon hosts if `CMAKE_OSX_ARCHITECTURES` is not set. This is necessary to prevent the toolchain from selecting its own default architecture based on that of the build tool (e.g., `x86_64`). If `CMAKE_<LANG>_COMPILER_TARGET` is set, its `-target` flag tells the compiler what architecture to use, so do not add `-arch arm64`. Fixes: #24599
* cmGeneratorTarget: Pass language to GetAppleArchs when possibleBrad King2023-03-151-1/+2
|
* cmGeneratorTarget: Convert GetAppleArchs output argument to return valueBrad King2023-03-151-3/+5
|
* Merge topic 'support_cubin_fatbin_optix_cuda_output'Brad King2023-03-141-6/+22
|\ | | | | | | | | | | | | | | 2def6a874b CUDA: Add support for CUBIN, FATBIN, and OPTIXIR compilation Acked-by: Kitware Robot <kwrobot@kitware.com> Acked-by: buildbot <buildbot@kitware.com> Merge-request: !8259
| * CUDA: Add support for CUBIN, FATBIN, and OPTIXIR compilationRobert Maynard2023-03-131-6/+22
| |
* | Merge topic 'target_sources-backtrace'Brad King2023-03-021-7/+6
|\ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | b909be9e23 target_sources: Fix backtrace on missing source 4a3e79048b Tests: Add RunCMake.target_sources case covering missing source Acked-by: Kitware Robot <kwrobot@kitware.com> Tested-by: buildbot <buildbot@kitware.com> Reviewed-by: Ben Boeckel <ben.boeckel@kitware.com> Merge-request: !8268
| * | target_sources: Fix backtrace on missing sourceBrad King2023-02-281-7/+6
| |/ | | | | | | | | | | | | | | | | If a source file is not found, the error message reports a backtrace. Previously the backtrace pointed at where the target was created. In the case of `target_sources`, the missing source may have been named elsewhere. Fixes: #24538
* | Merge topic 'Apple-handle-Text-Stubs'Brad King2023-03-021-45/+127
|\ \ | |/ |/| | | | | | | | | | | | | ede33f30cf Apple: Handle generation and comsuption of text-based stubs (.tbd files) fcbd723a50 Enhance support functions Acked-by: Kitware Robot <kwrobot@kitware.com> Acked-by: Brad King <brad.king@kitware.com> Merge-request: !8204
| * Apple: Handle generation and comsuption of text-based stubs (.tbd files)Marc Chevrier2023-03-011-30/+108
| | | | | | | | Fixes: #24123
| * Enhance support functionsMarc Chevrier2023-02-281-16/+20
| | | | | | | | | | * Avoid duplicate definiitions for IsExecutableWithExports, etc... * Add helper IsApple()
* | Add option to add SOVERSION to DLL namesRalf Habacker2023-02-271-1/+7
|/ | | | | | | Add variable/target property `[CMAKE_]DLL_NAME_WITH_SOVERSION`. Fixes: #24251 Signed-off-by: Ralf Habacker <ralf.habacker@freenet.de>
* cmGeneratorTarget: synthetic targets don't have output eitherBen Boeckel2023-02-141-0/+5
|
* cmMakefile: add support for a "synthesized" targetBen Boeckel2023-02-141-0/+5
| | | | | | It is a normal target, but will end up copying its internals from another target. Keep track of this state so that such copying can only occur when intended.
* cmTarget: store visibility as an `enum` rather than boolsBen Boeckel2023-02-141-0/+5
| | | | | | | | C++ modules are going to introduce a third concept of "synthesized" targets, so update logic where needed to avoid assuming "not imported? must be normal". Also add an accessor method to perform queries against the visibility.
* cmGeneratorTarget: `INTERFACE` targets with C++ modules are also "in"Ben Boeckel2023-02-081-3/+5
| | | | | | | | `INTERFACE` targets with C++ modules are basically BMI-only modules. It is unknown if they will be useful directly (due to ODR of the `module M;` initializers needing to live in some specific object file). However, they will be used to attach BMI-only compilations of `IMPORTED` C++ modules.
* cmGeneratorTarget: add a method to query if Fortran sources existBen Boeckel2023-02-011-0/+9
|
* Merge topic 'optimize-full-name-function'Brad King2023-01-191-68/+65
|\ | | | | | | | | | | | | | | a525f5f1bf cmGeneratorTarget: Cache full name components Acked-by: Kitware Robot <kwrobot@kitware.com> Acked-by: buildbot <buildbot@kitware.com> Merge-request: !8033
| * cmGeneratorTarget: Cache full name componentsPierre Testart2023-01-181-68/+65
| | | | | | | | | | Cache the result of cmGeneratorTarget::GetFullNameInternalComponents to improve performance.
* | cmValue: Use operator* explicitly to convert to std::string; avoid extra callVitaly Stakhovsky2023-01-161-2/+2
| |
* | STATIC_LIBRARY_OPTIONS: ensure correct expension of list inside a genexMarc Chevrier2022-12-201-7/+4
|/ | | | Fixes: #24258
* Merge topic 'clang-tidy-export-fixes-dir'Brad King2022-12-071-0/+18
|\ | | | | | | | | | | | | | | 232467eb1c clang-tidy: add <LANG>_CLANG_TIDY_EXPORT_FIXES_DIR property Acked-by: Kitware Robot <kwrobot@kitware.com> Acked-by: buildbot <buildbot@kitware.com> Merge-request: !7982
| * clang-tidy: add <LANG>_CLANG_TIDY_EXPORT_FIXES_DIR propertyKyle Edwards2022-12-061-0/+18
| | | | | | | | Fixes: #21362
* | Merge topic 'link-options-cache'Brad King2022-12-051-2/+4
|\ \ | |/ |/| | | | | | | | | 7c63372c22 cmGeneratorTarget: Fix regression in CUDA device link options Acked-by: Kitware Robot <kwrobot@kitware.com> Merge-request: !7981
| * cmGeneratorTarget: Fix regression in CUDA device link optionsBrad King2022-12-021-2/+4
| | | | | | | | | | | | Since commit f69d1872db (cmGeneratorTarget: Add caches to some functions, 2022-11-23) we cache the computed link options for a target. Cache the host and device link options separately.
* | Merge topic 'add-generator-target-caches'Brad King2022-11-301-1/+57
|\ \ | |/ | | | | | | | | | | | | f69d1872db cmGeneratorTarget: Add caches to some functions Acked-by: Kitware Robot <kwrobot@kitware.com> Tested-by: buildbot <buildbot@kitware.com> Merge-request: !7952
| * cmGeneratorTarget: Add caches to some functionsPierre Testart2022-11-281-1/+57
| | | | | | | | | | | | | | | | | | | | | | Add caches to the following cmGeneratorTarget functions in order to improve performance: - GetIncludeDirectories - GetCompileOptions - GetCompileDefinitions - GetPrecompileHeaders - GetLinkOptions - GetLinkDirectories
* | cmGeneratorTarget: factor out fileset info and scanning detectionBen Boeckel2022-11-231-0/+82
| |
* | cmGeneratorTarget: factor out dyndep support detectionBen Boeckel2022-11-231-0/+16
|/
* CMake: fix sizeof string literal violationsKyle Edwards2022-11-181-1/+1
|
* cmGeneratorExpression: Require cmake instanceKyle Edwards2022-11-111-22/+37
|
* Merge topic 'fix-cxx20-detection'Brad King2022-11-111-5/+12
|\ | | | | | | | | | | | | | | | | | | 5e7c8f44ac Ninja: Restore support for compilers not defining a C++ standard level Acked-by: Kitware Robot <kwrobot@kitware.com> Acked-by: buildbot <buildbot@kitware.com> Acked-by: Jaeden Amero <kitware@patater.com> Acked-by: Martin Kojtal <martin.kojtal@arm.com> Merge-request: !7896
| * Ninja: Restore support for compilers not defining a C++ standard levelLingkai Dong2022-11-101-5/+12
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Since commit 386465bf83 (cmTarget: add support for C++ module fileset types, 2022-04-08, v3.25.0-rc1~624^2~7), the Ninja generator checks for C++20 support using logic that requires `CMAKE_<LANG>_STANDARD_DEFAULT` to be non-empty. On some compilers, such as ARMClang, CMake does not automatically detect and set default language standards, thus causing `HaveStandardAvailable` to raise an internal error. To fix this issue, if `CMAKE_CXX_STANDARD_DEFAULT` is empty, assume all standards to be supported instead of calling `HaveStandardAvailable`. This is consistent with how `CompileFeaturesNode::Evaluate` handles this case. Fixes: #24146