summaryrefslogtreecommitdiff
path: root/Source/cmake.h
Commit message (Collapse)AuthorAgeFilesLines
* Merge topic 'extended-profiling'Brad King2022-10-281-3/+12
|\ | | | | | | | | | | | | | | | | 0fe7aae91f cmake: Add profiling events for configure and generate 3d6a8d7eac cmMakefileProfilingData: Refactor to use RAII Acked-by: Kitware Robot <kwrobot@kitware.com> Tested-by: buildbot <buildbot@kitware.com> Merge-request: !7828
| * cmMakefileProfilingData: Refactor to use RAIIKyle Edwards2022-10-261-3/+12
| | | | | | | | And add a more generic StartEntry() method.
* | Merge topic 'cmake-presets-workflow-arguments'Brad King2022-10-271-1/+12
|\ \ | |/ |/| | | | | | | | | | | | | | | | | 7ecbe324b0 cmake --workflow: add --fresh option 7d9aa0f00c cmake::Workflow: Refactor to use enum class argument 322193afcd cmake --workflow: print usage and exit on unrecognized argument 70aef29427 cmake --workflow: print usage message Acked-by: Kitware Robot <kwrobot@kitware.com> Acked-by: buildbot <buildbot@kitware.com> Merge-request: !7825
| * cmake --workflow: add --fresh optionKyle Edwards2022-10-261-1/+7
| | | | | | | | Fixes: #24073
| * cmake::Workflow: Refactor to use enum class argumentKyle Edwards2022-10-261-1/+6
| |
* | try_compile: Propagate --trace through try_compileMatthew Woehlke2022-10-111-1/+11
|/ | | | | Add ability to specify another cmake instance from which to get the trace output target. Use this during try_compile.
* cmake: Add --workflow modeKyle Edwards2022-09-271-0/+14
| | | | Fixes: #23118
* CMake: Support upcoming C++26 language levelRobert Maynard2022-08-311-2/+5
|
* Add cmake_language(GET_MESSAGE_LOG_LEVEL) sub commandAlexandru Croitor2022-06-281-1/+2
| | | | | | | | | | | | | | | | | The new sub-command writes a string representation of the current log level to the output variable given to the sub-command. Given that the log-level might be set either via the --log-level command line option or via the CMAKE_MESSAGE_LOG_LEVEL cache / regular variables, the priority for each of the log level sources is as follows, with the first one being the highest: 1) --log-level 2) CMAKE_MESSAGE_LOG_LEVEL regular variable 3) CMAKE_MESSAGE_LOG_LEVEL cache variable 4) default log level (STATUS) Fixes: #23572
* Move LogLevel enum out of cmake.h headerAlexandru Croitor2022-06-241-17/+4
| | | | | | | Move LogLevel enum into the cmMessageType.h header in preparation for a new log level querying feature. Wrap the enum into a new Message namespace. Adjust all code usages.
* COMPILE_WARNING_AS_ERROR: Add command-line optionMartin Duffy2022-05-181-0/+3
| | | | | | | Add command-line option `--compile-no-warning-as-error` to ignore value of `COMPILE_WARNING_AS_ERROR`. Issue: #19085
* cmake: Add --fresh option to clear the cache and start from scratchBrad King2022-03-221-0/+1
| | | | | | | Simplify the workflow to re-run CMake from scratch as if a build tree were never before processed, regardless of whether it has been. Fixes: #23119
* cmake: Always prefer the last source directory providedRobert Maynard2022-03-171-9/+2
| | | | Fixes: #23334
* cmake: When given multiple source paths use last instead of firstRobert Maynard2022-02-171-0/+23
| | | | | | | | When given two source paths via `-S` or just directory paths prefer the last one. When the paths are mixed always prefer the last `-S` entry. Fixes: #23238
* cmake::GetDebugFindPkgOutput: Use consistent argument nameCraig Scott2022-02-141-1/+1
| | | | | | The argument name used in the class declaration didn't match the one used in the implementation file. The one in the header appears to be a cut-n-paste from GetDebugFindOutput(), but the implementation makes it clear that "pkg" better infers what the argument represents than "var".
* Merge topic 'vs-package-restore'Brad King2022-01-241-2/+3
|\ | | | | | | | | | | | | | | | | | | 9aa7831f05 Presets: add resolve packages setting to build presets. b2f8f0bb87 cmGlobalVisualStudio10Generator: Auto restore NuGet packages. 193b8fca52 cmBuildOptions: Split build arguments into separate object. 6a10103493 Help: Update preset schema description for version 3 entries. Acked-by: Kitware Robot <kwrobot@kitware.com> Merge-request: !6761
| * cmBuildOptions: Split build arguments into separate object.Carsten Rudolph2022-01-221-2/+3
| |
* | cmake: Warn about unnecessary paths on command lineRobert Maynard2022-01-201-1/+1
|/ | | | | | We can't make it an error as that would break existing behavior. Fixes: #23110
* Refactor: Rename cmCMakePresetsFile to cmCMakePresetsGraphKyle Edwards2022-01-061-3/+3
| | | | And change all references to "file" to say "graph" instead.
* cmake: Add filtered debug-find optionsJohn Parent2021-12-171-1/+8
| | | | | | | | | | Add a `--debug-find-pkg=` option to debug find calls for specific packages. Add a `--debug-find-var=` option to debug find calls for specific return variables. Fixes: #21880
* Rename cmProp in cmValueMarc Chevrier2021-09-211-8/+8
|
* AddCacheEntry accept cmProp or std::stringMarc Chevrier2021-09-101-0/+12
|
* Enhancement: SetProperty accept cmProp or std::stringMarc Chevrier2021-08-251-0/+5
| | | | | Methods SetProperty of classes cmPropertyMap, cmStateDirectory and cmMakefile accept now cmProp or std::string as argument.
* cmake: Model normal and try-compile project kinds explicitlyBrad King2021-07-121-2/+2
| | | | | Construct with the project kind instead of mutating state after construction.
* HIP: Add language to CMakeRobert Maynard2021-06-071-1/+10
|
* class cmake: Store working directory at cmake launchMarc Chevrier2021-05-111-0/+9
|
* cmake: add support for --toolchain command argumentRobert Maynard2021-04-151-0/+2
|
* cmake: add support for --install-prefix command argumentRobert Maynard2021-03-041-0/+2
| | | | Fixes: #21781
* C23 supportRaul Tambre2021-02-251-0/+1
|
* C17 supportRaul Tambre2021-02-251-0/+1
| | | | Implements #17755.
* cmake-presets: Add build and test presetsSam Freed2021-02-011-5/+5
| | | | Fixes: #21391
* CUDA, CXX, OBJCXX: C++23 support with Clang 12Raul Tambre2020-12-081-1/+3
| | | | | Clang 12 landed initial support for C++23 language mode flag -std={c|gnu}++2b in commit 6627a3c2873fdf7ccba1a1573371079be48b36e8.
* Merge topic 'cmake-presets-help-flag'Brad King2020-10-281-2/+0
|\ | | | | | | | | | | | | c619be2784 ccmake: Don't list --preset in --help Acked-by: Kitware Robot <kwrobot@kitware.com> Merge-request: !5428
| * ccmake: Don't list --preset in --helpKyle Edwards2020-10-271-2/+0
| | | | | | | | | | | | And show available options in cmake-gui. Fixes: #21313
* | Constify some code as suggested by clang-tidyCengizhan Pasaoglu2020-10-201-8/+8
|/
* CMake: Add presets functionalityKyle Edwards2020-10-051-6/+48
|
* Refactor: Add allowArch parameter to cmake::CreateGlobalGenerator()Kyle Edwards2020-10-051-1/+1
|
* cmake::GetCacheDefinition: Return cmPropvvs314152020-09-281-1/+1
|
* Modernize: Use #pragma once in all header filesKitware Robot2020-09-031-4/+1
| | | | | | | | | | | | | | | | #pragma once is a widely supported compiler pragma, even though it is not part of the C++ standard. Many of the issues keeping #pragma once from being standardized (distributed filesystems, build farms, hard links, etc.) do not apply to CMake - it is easy to build CMake on a single machine. CMake also does not install any header files which can be consumed by other projects (though cmCPluginAPI.h has been deliberately omitted from this conversion in case anyone is still using it.) Finally, #pragma once has been required to build CMake since at least August 2017 (7f29bbe6 enabled server mode unconditionally, which had been using #pragma once since September 2016 (b13d3e0d)). The fact that we now require C++11 filters out old compilers, and it is unlikely that there is a compiler which supports C++11 but does not support #pragma once.
* Add ISPC compiler support to CMakeRobert Maynard2020-08-281-1/+3
|
* cmake: Remove broken '--warn-unused-vars' optionBrad King2020-06-291-3/+0
| | | | | | | | | | | | | This option has been broken since commit b9f9915516 (cmMakefile: Remove VarUsageStack., 2015-05-17, v3.3.0-rc1~52^2). That commit removed the check that an initialized variable has actually been used and caused the option to warn on every variable ever set. This was not caught by the test suite because the test for the feature only checked that warnings appear when needed and not that they do not appear when not needed. The option was never very practical to use. Remove it to avoid the runtime cost of usage tracking and checks for every variable (which we were doing even when the option was not used).
* Refactor file extension queries to be more consistentRobert Maynard2020-06-221-25/+14
| | | | | It was very easy to forgot to check against all language file extensions. This updates the internal API to have a unified API.
* Single location for cmProp typedefVitaly Stakhovsky2020-06-011-0/+1
|
* Refactoring: Third-parties public headers are under cm3p prefixMarc Chevrier2020-05-071-1/+1
| | | | Fixes: #20666
* Merge topic 'cmprop-getglobalprop'Brad King2020-03-271-1/+1
|\ | | | | | | | | | | | | c84cf42897 cmState::GetGlobalProperty: return cmProp Acked-by: Kitware Robot <kwrobot@kitware.com> Merge-request: !4521
| * cmState::GetGlobalProperty: return cmPropVitaly Stakhovsky2020-03-251-1/+1
| |
* | use cm::string_view for language extension lookupsRolf Eike Beer2020-03-231-6/+8
|/ | | | | | | Once the list of extensions is build the set is just a copy of the vector and not modified anymore. Use a string_view for the members of the set, which saves a small amount of memory. It also makes possible to use string_views as lookup keys, so the callers do not need to create copies for the extensions anymore.
* cmake: add command line options to output script profiling dataWouter Klouwen2020-03-071-0/+12
| | | | | | | | | | | | | | | For users of CMake who want to optimize their scripts if they take a while to run, this commit adds the ability to output profiling data. To enable this output, it adds the two command line parameters to select the output path and format. This commit adds the first profiling format of type ``google-trace``, which is the output is a JSON file containing Duration events as per the Google Trace Format specification: https://docs.google.com/document/d/1CvAClvFfyA5R- PhYUmn5OOQtYMH4h6I0nSsKchNAySU/preview#
* Merge topic 'ninja-1.10'Brad King2020-01-281-0/+3
|\ | | | | | | | | | | | | | | | | | | | | | | | | ccaa0bccc4 Ninja: Do not clean metadata when re-generating inside a running build 657820a00b Ninja: Track when running to re-generate during a build b12b013028 Ninja: Factor metadata cleanup into dedicated method 5d92e60d81 Ninja: Skip cleandead and recompact if build.ninja is missing dd0a4718fd Ninja: Fix CMAKE_NINJA_OUTPUT_PATH_PREFIX with Ninja 1.10 0944caaebb Tests: Fix RunCMake.CMP0037 test with Ninja 1.10 9d4883cce5 Tests: Fix RunCMake.Ninja test for Ninja 1.10 Acked-by: Kitware Robot <kwrobot@kitware.com> Merge-request: !4290
| * Ninja: Track when running to re-generate during a buildBrad King2020-01-271-0/+3
| | | | | | | | | | Tell CMake explicitly when it is re-running inside a `ninja` invocation to re-generate the build system.