1
0
mirror of https://github.com/Kitware/CMake.git synced 2025-10-20 21:40:15 +08:00
Commit Graph

411 Commits

Author SHA1 Message Date
Brad King
0d2d5a229c Merge topic 'use-linker-depfile'
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
2023-05-04 09:06:23 -04:00
Brad King
28dd02c3ba Merge topic 'autogen-system-include'
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
2023-05-04 09:01:08 -04:00
Marc Chevrier
375e6fdbbe Link step: use linker dependency linker file
Based on work done by @ben.boeckel (!8051)

Fixes: #22217
2023-05-03 17:08:07 +02:00
Orkun Tokdemir
033dc7ee2f Autogen: Add AUTOGEN_USE_SYSTEM_INCLUDE target property
`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.
2023-05-03 09:03:46 -04:00
Alex Neundorf
35566b48b4 VS: Add variables to initialize debugger-related properties
Add variables to initialize target properties `VS_DEBUGGER_COMMAND`,
`VS_DEBUGGER_COMMAND_ARGUMENTS`, `VS_DEBUGGER_ENVIRONMENT`, and
`VS_DEBUGGER_WORKING_DIRECTORY`.
2023-05-01 13:39:00 -04:00
Brad King
5386dc582b Merge topic 'autogen-exe-vars'
b3d1797508 Autogen: Add CMAKE_AUTO*_EXECUTABLE variables

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !8352
2023-03-23 08:46:45 -04:00
Orkun Tokdemir
b3d1797508 Autogen: Add CMAKE_AUTO*_EXECUTABLE variables
Add the `CMAKE_AUTOMOC_EXECUTABLE`, `CMAKE_AUTOUIC_EXECUTABLE`, and
`CMAKE_AUTORCC_EXECUTABLE` variables to initialize the corresponding
`AUTO{MOC,UIC,RCC}_EXECUTABLE` target properties.

Fixes: #20071
2023-03-22 07:31:56 -04:00
halx99
6546305b01 VS: Add CMAKE_VS_WINDOWS_TARGET_PLATFORM_MIN_VERSION variable
Provide a way to initialize the `VS_WINDOWS_TARGET_PLATFORM_MIN_VERSION`
target property on targets.  It sets `WindowsTargetPlatformMinVersion`
in `.vcxproj` files.
2023-03-15 10:03:16 -04:00
Brad King
1d7fb31778 Merge topic 'Apple-handle-Text-Stubs'
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
2023-03-02 09:53:03 -05:00
Marc Chevrier
ede33f30cf Apple: Handle generation and comsuption of text-based stubs (.tbd files)
Fixes: #24123
2023-03-01 12:23:28 +01:00
Ralf Habacker
a7f9c7da26 Add option to add SOVERSION to DLL names
Add variable/target property `[CMAKE_]DLL_NAME_WITH_SOVERSION`.

Fixes: #24251
Signed-off-by: Ralf Habacker <ralf.habacker@freenet.de>
2023-02-27 09:18:34 -05:00
Abdelmaged Khalifa
ea2a05f402 Add variable CMAKE_ADD_CUSTOM_COMMAND_DEPENDS_EXPLICIT_ONLY
Add CMake variable `CMAKE_ADD_CUSTOM_COMMAND_DEPENDS_EXPLICIT_ONLY` to enable
option `DEPENDS_EXPLICIT_ONLY` on all uses of `add_custom_command`.

Fixes: #17097
2023-02-17 17:12:12 +02:00
Alexander Neundorf
9a7612d2d0 Kate: make it possible to force a mode for the "files" entry
By default, kate will try to autodetect whether the project is
a svn or git checkout or not.
In case this does not give a satisfying result, the user can now
set CMAKE_KATE_FILES_MODE to the mode he wants.
2023-02-06 10:21:19 -05:00
Alexander Neundorf
8a7aa2642b Help: add documentation for Kate-related variable 2023-02-03 23:19:13 +01:00
Brad King
5ce0f03cce VS: Add a variable to report the Visual Studio version build number
VS 2017 and above come with a Visual Studio Installer tool that tracks
four-component Visual Studio version numbers.  We already detect the VS
version number because it is needed to make some generation decisions.
Provide the number to projects in a `CMAKE_VS_VERSION_BUILD_NUMBER`
variable so they can use it similarly.

Fixes: #24230
2022-12-07 17:49:04 -05:00
Kyle Edwards
232467eb1c clang-tidy: add <LANG>_CLANG_TIDY_EXPORT_FIXES_DIR property
Fixes: #21362
2022-12-06 10:39:29 -05:00
Ben Boeckel
a02d792c6e cxxmodules: add properties to control scanning
The `CXX_SCAN_FOR_MODULES` property may be used to control scanning for
targets and for source files rather than assuming "C++20 always needs to
be scanned".
2022-11-18 07:54:31 -05:00
Craig Scott
3de30134f1 Help: Re-sort property, variable and compiler id lists 2022-10-09 13:34:05 +11:00
Brad King
01a25d72c6 Merge topic 'add_tasking_compiler'
94df5b6ef1 Tasking: Add support for several compiler toolsets

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !7491
2022-09-15 09:19:58 -04:00
Christoph Seitz
94df5b6ef1 Tasking: Add support for several compiler toolsets
Add support for the Tasking compiler toolset:

* TriCore Compiler Toolset 6.3 (with TriCore, ARM, MCS,
  8051 and PCP architecture compilers)
* SmartCode Compiler Toolset 10.1 (with TriCore, ARC, MCS,
  8051 architecture compilers)
* ARM Compiler 6.0
* MCS Complier 3.3
* 8051 Compiler 7.2

Fixes: #23756
2022-09-14 09:58:50 -04:00
Brad King
c3e68020d6 Merge topic 'MsvcDebugInformationFormatAbstraction'
a858466aac MSVC: Add test for debug information format
0e96a20478 MSVC: Add abstraction for debug information format
d4c8111da4 Clang/Windows: Clarify name of internal runtime library flags variables

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !7606
2022-09-14 09:21:27 -04:00
Glen Chung
0e96a20478 MSVC: Add abstraction for debug information format
Replace our hard-coded default for `/Zi` with a first-class abstraction
to select the debug information format an enumeration of logical
names.  We've long hesitated to do this because the idea of "debug
information format" touches on related concepts on several platforms.
Avoid that scope creep by simply defining an abstraction that applies
only when targeting the MSVC ABI on Windows.

Removing the old default flag requires a policy because existing
projects may rely on string processing to edit them and choose a
runtime library under the old behavior.  Add policy CMP0141 to
provide compatibility.

Fixes: #10189
2022-09-14 09:12:47 -04:00
Cristian Adam
caffb15d09 LINUX: Set CMAKE_HOST_LINUX variable when running on a Linux host
Relates: #23840
2022-09-09 20:10:43 +02:00
Cristian Adam
1ea8b8ed86 BSD: Set CMAKE_HOST_BSD variable on a BSD host
Also the BSD variable will be set in CMake scripting mode (-P).

Relates: #23853
2022-09-06 01:15:44 +02:00
Cristian Adam
288f72efea BSD: Only use BSD as variable for target BSD system
Instead of having multiple boolean variables, we only have one
string variable: BSD with the name of the target BSD system.

Relates: #23853
2022-09-06 01:02:34 +02:00
Brad King
fc4451dd31 Merge topic 'xcode-add-gpu-validation-and-default-configuration'
740bee97bd Xcode: Add settings to control a scheme's launch configuration
39456c70e1 Xcode: Add settings to control a scheme's GPU Validation values
4034272ed8 gitignore: Tell Git to ignore the .cache/ directory

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !7581
2022-08-31 09:43:50 -04:00
PatriceJiang
740bee97bd Xcode: Add settings to control a scheme's launch configuration 2022-08-30 10:28:27 -04:00
PatriceJiang
39456c70e1 Xcode: Add settings to control a scheme's GPU Validation values 2022-08-30 10:26:48 -04:00
Cristian Adam
a20d7a9707 BSD: Set *BSD variables when targeting a *BSD system
Fixes: #23853
2022-08-21 09:27:59 +10:00
Cristian Adam
62cd3904bf variable: Set LINUX variable on Linux target systems
Fixes: #23840
2022-08-12 07:20:05 +10:00
Brad King
5d8289116d Merge topic 'vs-compile-batching'
9a0a94fdaa VS: Add variable to to turn off Visual Studio compile batching
a7ebb73929 Help: Improve formatting in VS_NO_COMPILE_BATCHING docs

Acked-by: Kitware Robot <kwrobot@kitware.com>
Acked-by: buildbot <buildbot@kitware.com>
Merge-request: !7405
2022-06-23 09:23:56 -04:00
Brad King
9a0a94fdaa VS: Add variable to to turn off Visual Studio compile batching
Extend the change from commit b764c7c273 (VS: Add property to turn off
Visual Studio compile batching, 2022-02-07, v3.24.0-rc1~710^2) by
adding a variable to initialize the property on every target.

Issue: #23179
Fixes: #23639
2022-06-22 12:07:03 -04:00
Harry Mallon
a1a0ae3ad4 Xcode: Add Xcode SCHEME control for 'Launch' control 2022-06-15 19:02:56 +01:00
Kyle Edwards
259c265112 VERIFY_HEADER_SETS: Rename to VERIFY_INTERFACE_HEADER_SETS
Issue: #23448
2022-05-18 10:18:40 -04:00
Brad King
a7cd15a61c Merge topic 'try_compile-project-platform-vars'
a6562ff579 try_compile: Add option to skip passing platform variables
4843a37676 try_compile: Propagate platform variables in project-mode too

Acked-by: Kitware Robot <kwrobot@kitware.com>
Tested-by: buildbot <buildbot@kitware.com>
Merge-request: !7265
2022-05-17 08:57:55 -04:00
Brad King
a6562ff579 try_compile: Add option to skip passing platform variables
Add a `CMAKE_TRY_COMPILE_NO_PLATFORM_VARIABLES` variable to tell
`try_compile` not to pass platform variables to the test project.

Issue: #23219
2022-05-16 10:47:21 -04:00
Brad King
c4ed5341c4 Merge topic 'CMAKE_PROJECT_TOP_LEVEL_INCLUDES'
a6c34b0353 project(): Add new CMAKE_PROJECT_TOP_LEVEL_INCLUDES file injection point
8aa29a1793 CMakeDetermineSystem: Remove unreachable code

Acked-by: Kitware Robot <kwrobot@kitware.com>
Acked-by: buildbot <buildbot@kitware.com>
Merge-request: !7250
2022-05-16 09:26:59 -04:00
Craig Scott
a6c34b0353 project(): Add new CMAKE_PROJECT_TOP_LEVEL_INCLUDES file injection point
Fixes: #22685
2022-05-13 18:03:36 +10:00
Brad King
79b64690d9 Merge topic 'werror-property'
76a08cd253 COMPILE_WARNING_AS_ERROR: Add options to treat warnings as errors

Acked-by: Kitware Robot <kwrobot@kitware.com>
Tested-by: buildbot <buildbot@kitware.com>
Acked-by: Michael Hirsch <michael@scivision.dev>
Merge-request: !7187
2022-05-10 10:30:42 -04:00
Martin Duffy
76a08cd253 COMPILE_WARNING_AS_ERROR: Add options to treat warnings as errors
Add `COMPILE_WARNING_AS_ERROR` target property and supporting
`CMAKE_COMPILE_WARNING_AS_ERROR` variable.

`COMPILE_WARNING_AS_ERROR` is initialized by
`CMAKE_COMPILE_WARNING_AS_ERROR`. It is a boolean variable. If it is
true, it expands to a different flag depending on the compiler such that
any warnings at compile will be treated as errors.

Supports compiler ids that I could find a relevant flag for.
2022-05-06 12:14:37 -04:00
Cameron Cawley
33da5824ac OpenWatcom: Allow specifying the runtime library
Add a `CMAKE_WATCOM_RUNTIME_LIBRARY` variable to control the
runtime library selection.  Add policy CMP0136 to switch to
in place of the old hard-coded default flags.

Fixes: #23178
2022-05-06 10:40:58 -04:00
Craig Scott
29e31e2825 Packages: Integrate FetchContent and find_package()
Allow FetchContent_MakeAvailable() to try a call to
find_package() first, or redirect a find_package() call to
FetchContent_MakeAvailable(). The user can set variables
to control which of these are allowed or tried by default.

Fixes: #21687
2022-05-03 16:48:11 +10:00
Robert Maynard
42f7e39789 Find: Support per call disabling of CMAKE_INSTALL_PREFIX
Fixes #23359
2022-04-15 09:33:55 -04:00
Brad King
c508935dad Merge topic 'adsp-platform-and-compilers'
87142bbd5f ADSP: Add dedicated platform module
e9eabb0dcd ADSP: Configure compiler in compiler module
88b38f531a ADSP: Support both VDSP++ and CCES for ADSP compilers

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !7123
2022-04-06 12:04:43 -04:00
Chris Wright
87142bbd5f ADSP: Add dedicated platform module 2022-04-04 17:05:09 +01:00
Gregor Jasny
53ca6edd8a xcode: add support for xcconfig files
Fixes: #18420
2022-04-03 22:39:34 +02:00
Kyle Edwards
c798744f81 FILE_SET: Add VERIFY_HEADER_SETS target property
Fixes: #23338
2022-03-29 13:58:27 -04:00
John Parent
2f1ffa003c find_package: Add support for default GLOBAL imported targets
Allow find package to promote scope of imported targets by specifying
an argument to `find_package` or by specifying a CMake variable.
    * Add support for CMAKE_GLOBAL_IMPORT_SCOPE variable
    * Add support for GLOBAL argument to find_package

Additionally add testing for above features.
2022-03-10 12:44:36 -05:00
Brad King
cbd36eac23 Merge topic 'ctest_truncate'
140704d443 ctest: add option for output truncation
359e5b17d8 presets: bump version to v5
4634de335b cmCTestTestHandler: refactor CleanTestOutput method

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !6993
2022-03-09 12:17:44 -05:00
Brad King
51e81d1f73 Merge topic 'color-diagnostics'
6ab9fbd43b color: Add tests for CMAKE_COLOR_DIAGNOSTICS
78adb1b952 color: Add CMAKE_COLOR_DIAGNOSTICS environment variable
884d9de8b7 color: Introduce CMAKE_COLOR_DIAGNOSTICS variable

Acked-by: Kitware Robot <kwrobot@kitware.com>
Acked-by: buildbot <buildbot@kitware.com>
Acked-by: Frank Dana <ferdnyc@gmail.com>
Merge-request: !6990
2022-03-09 12:15:53 -05:00