summaryrefslogtreecommitdiffstats
path: root/Source/cmMakefile.cxx
Commit message (Collapse)AuthorAgeFilesLines
* cmCustomCommand: Track main dependency explicitlyNAKAMURA Takumi2021-12-141-9/+6
| | | | | | | Store the main dependency as the first entry in the dependency list plus a boolean member indicating its existence. Note that this slightly changes existing behavior: the main dependency was previously the last entry of the dependency list.
* cmListFileBacktrace: Remove unused "bottom" entryBrad King2021-12-081-1/+0
| | | | | All uses of `GetBottom` by clients have been removed, so drop the method and its supporting infrastructure.
* Merge topic 'env-init-configs'Brad King2021-11-231-1/+2
|\ | | | | | | | | | | | | | | 5b1ed2a646 try_compile: Do not use CMAKE_BUILD_TYPE or CMAKE_CONFIGURATION_TYPES env vars Acked-by: Kitware Robot <kwrobot@kitware.com> Acked-by: buildbot <buildbot@kitware.com> Merge-request: !6755
| * try_compile: Do not use CMAKE_BUILD_TYPE or CMAKE_CONFIGURATION_TYPES env varsBrad King2021-11-221-1/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Since: * commit e216b9bbd3 (cmake: Allow CMAKE_BUILD_TYPE to be set by environment variable, 2021-06-29, v3.22.0-rc1~503^2~1) * commit ef56eefc9b (cmake: Allow CMAKE_CONFIGURATION_TYPES to be set by environment variable, 2021-06-29, v3.22.0-rc1~503^2) the environment variables are supposed to provide defaults for settings the user otherwise can control via cache entries. However, they accidentally affect `try_compile` projects too, which are supposed to be programmatically controlled. Fixes: #22935
* | cmMakefile: Simplify Add*Command and adopt to cmAddCustom*CommandNAKAMURA Takumi2021-11-181-92/+34
| |
* | cmMakefile: Simplify detail:::Add{Custom,Utility}CommandNAKAMURA Takumi2021-11-181-41/+64
| | | | | | | | | | | | | | | | | | Note 1: `detail::AddCustomCommandToTarget()` resets cc, since cc is not moved away. Note 2: In `detail::AddUtilityCommand()`, a few vars are preserved before using. Their refs will be alive in most cases, but cc might be destroyed in the future.
* | cmMakefile: Introduce GeneratorAction as the class.NAKAMURA Takumi2021-11-181-2/+8
| |
* | cmMakefile: Move CMP0116 lookup into Add{Custom,Utility}CommandNAKAMURA Takumi2021-11-181-22/+22
| | | | | | | | Avoid repeating it at every call site.
* | Source: Replace most calls to sprintf with snprintfSean McBride2021-10-251-2/+2
| |
* | Add deprecation warnings for policies CMP0094 and belowBrad King2021-10-081-2/+3
|/ | | | | | | The OLD behaviors of all policies are deprecated, but only by documentation. Add an explicit deprecation diagnostic for policies introduced in CMake 3.15 and below to encourage projects to port away from setting policies to OLD.
* cmMakefile: Fix compilation on EDG-based compilers such as LCCmakise-homura2021-10-011-5/+4
| | | | | | | | | | Compilers based on EDG frontend sometimes throw an internal error while using `this->` at some circumstances. While it is up to be fixed in future versions of front end, this bug still occurs in some modern compilers, such as LCC for Elbrus CPUs, and probably others (maybe ICC). It caused CMake to be unbuildable by these compilers. This patch fixes it.
* Source: Fix clang -Wimplicit-fallthrough warningsSean McBride2021-09-281-4/+11
|
* Rename cmProp in cmValueMarc Chevrier2021-09-211-40/+41
|
* remove cmToCStr functionMarc Chevrier2021-09-191-2/+2
|
* cmSystemTools::VersionCompare: use std::string for argumentsMarc Chevrier2021-09-171-2/+1
|
* Merge topic 'enh-AddCacheEntry-accepts-new-types'Marc Chevrier2021-09-101-4/+4
|\ | | | | | | | | | | | | | | f84193292c Use new AddCacheEntry signatures 3c2e58eeb8 AddCacheEntry accept cmProp or std::string Acked-by: Kitware Robot <kwrobot@kitware.com> Merge-request: !6495
| * Use new AddCacheEntry signaturesMarc Chevrier2021-09-101-4/+4
| |
* | Refactor: Convert parallel string/backtrace vectors to BT vectorsKyle Edwards2021-09-031-38/+10
|/
* Refactor: Use new SetProperty signaturesMarc Chevrier2021-08-251-8/+7
|
* Enhancement: SetProperty accept cmProp or std::stringMarc Chevrier2021-08-251-0/+4
| | | | | Methods SetProperty of classes cmPropertyMap, cmStateDirectory and cmMakefile accept now cmProp or std::string as argument.
* cmProp: refactoring: transform alias in classMarc Chevrier2021-08-081-8/+3
| | | | | | To handle safely the values used by CMake variables and properties, introduce the class cmProp as a replacement from the simple pointer to std::string instance.
* 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.
* cmMakefile: Split out CreateNewTarget from AddNewTargetNAKAMURA Takumi2021-07-081-6/+14
| | | | `CreateNewTarget` tells whether the target is inserted or not.
* Merge topic 'env-init-configs'Brad King2021-07-011-0/+17
|\ | | | | | | | | | | | | | | | | | | | | ef56eefc9b cmake: Allow CMAKE_CONFIGURATION_TYPES to be set by environment variable e216b9bbd3 cmake: Allow CMAKE_BUILD_TYPE to be set by environment variable 6986a382a9 Help: Document when CMAKE_BUILD_TYPE and CMAKE_CONFIGURATION_TYPES are set e96169a3ec Help: Cross-reference CMAKE_CONFIGURATION_TYPES from CMAKE_BUILD_TYPE 03bd9c4c10 cmMakefile: Add helper to initialize CMAKE_CONFIGURATION_TYPES Acked-by: Kitware Robot <kwrobot@kitware.com> Merge-request: !6291
| * cmake: Allow CMAKE_CONFIGURATION_TYPES to be set by environment variableBrad King2021-06-301-1/+5
| | | | | | | | | | | | | | | | When no `CMAKE_CONFIGURATION_TYPES` is explicitly specified while creating a new build tree, check for an environment variable of the same name. Issue: #20983
| * cmMakefile: Add helper to initialize CMAKE_CONFIGURATION_TYPESBrad King2021-06-301-0/+13
| | | | | | | | | | Factor out duplicate code from the Ninja Multi-Config, Visual Studio, and Xcode generators.
* | Add deprecation warnings for policies CMP0088 and belowBrad King2021-06-301-4/+3
|/ | | | | | | The OLD behaviors of all policies are deprecated, but only by documentation. Add an explicit deprecation diagnostic for policies introduced in CMake 3.14 and below to encourage projects to port away from setting policies to OLD.
* CMP0126: Add control for warningsMarc Chevrier2021-06-291-3/+20
| | | | Fixes: #22353
* cmState: Record imported target names in each directoryBrad King2021-06-101-0/+1
| | | | | Model the change after commit 089868a244 (cmState: Record buildsystem target names in each directory, 2016-09-16, v3.7.0-rc1~79^2~3).
* cmMakefile: Register explicit object sources more efficientlyBrad King2021-05-281-1/+2
| | | | `AddTargetObject` knows the location of object files.
* Merge topic 'set-cache-keep-normal-variable'Brad King2021-05-251-4/+4
|\ | | | | | | | | | | | | | | d96eb55282 set(CACHE): do not remove normal variable Acked-by: Kitware Robot <kwrobot@kitware.com> Reviewed-by: Ben Boeckel <ben.boeckel@kitware.com> Merge-request: !6146
| * set(CACHE): do not remove normal variableMarc Chevrier2021-05-201-4/+4
| | | | | | | | Fixes: #22038
* | Merge branch 'master' into cmp0082-exclude-from-allKyle Edwards2021-05-241-6/+22
|\ \ | |/
| * Merge topic 'find_item-consistent-behavior-cache-variables'Brad King2021-05-131-0/+2
| |\ | | | | | | | | | | | | | | | | | | | | | | | | 08db1341a6 find_*: ensure consistent behavior for cache variables f5fa6d53b0 class cmake: Store working directory at cmake launch b1729200c3 find_*: refactor cache variable handling Acked-by: Kitware Robot <kwrobot@kitware.com> Merge-request: !6110
| | * find_*: ensure consistent behavior for cache variablesMarc Chevrier2021-05-121-0/+2
| | | | | | | | | | | | Fixes: #22121
| * | Source: Minor code improvementsVitaly Stakhovsky2021-05-111-3/+3
| |/
| * Source: Fix typos and spelling in commentsJosef Angstenberger2021-05-071-1/+1
| |
| * foreach(): loop variables are only available in the loop scopeMarc Chevrier2021-04-281-0/+14
| | | | | | | | Fixes: #20553
| * Treat '.ixx' and '.cppm' files as C++ sourcesAndrew Gilewsky2021-03-221-1/+1
| | | | | | | | | | These extensions are used by convention for C++ modules and interface units with MSVC.
| * Merge topic 'autogen-cmp0116-fix'Brad King2021-02-241-23/+29
| |\ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 339dbc901f Help: Note that CMP0116 is recorded at the time of CC creation e3740e020e Tests: Test Qt autogen target with CMP0116 set to WARN cf34011ce7 Tests: Test per-CC behavior of CMP0116 3a95503512 Ninja: Use CMP0116 status recorded at time of custom command's creation f01f10e8fb cmCustomCommand: Record value of CMP0116 at time of creation Acked-by: Kitware Robot <kwrobot@kitware.com> Merge-request: !5848
| * | Add deprecation warnings for policies CMP0081 and belowBrad King2021-02-101-1/+1
| | | | | | | | | | | | | | | | | | | | | The OLD behaviors of all policies are deprecated, but only by documentation. Add an explicit deprecation diagnostic for policies introduced in CMake 3.13 and below to encourage projects to port away from setting policies to OLD.
* | | CMP0082: Check EXCLUDE_FROM_ALL property at generate timeKyle Edwards2021-05-241-1/+1
| |/ |/| | | | | Fixes: #22234
* | cmCustomCommand: Record value of CMP0116 at time of creationKyle Edwards2021-02-231-23/+29
|/
* Merge topic 'issue-19198'Brad King2021-02-021-3/+3
|\ | | | | | | | | | | | | | | 255df8622b file(GENERATE): Support new line style Acked-by: Kitware Robot <kwrobot@kitware.com> Acked-by: Brad King <brad.king@kitware.com> Merge-request: !5649
| * file(GENERATE): Support new line styleAsit Dhal2021-02-011-3/+3
| | | | | | | | Fixes: #19198
* | cmInstallGenerator: Add backtrace to all install generatorsBrad King2021-01-281-1/+1
|/
* clang-tidy: fix `readability-qualified-auto` warningsBen Boeckel2021-01-271-2/+2
|
* Merge topic 'trace_expand_bracket'Brad King2021-01-121-1/+1
|\ | | | | | | | | | | | | e6e7f2cab9 cmMakefile: Don't expand bracket arguments in --trace-expand Acked-by: Kitware Robot <kwrobot@kitware.com> Merge-request: !5687
| * cmMakefile: Don't expand bracket arguments in --trace-expandRaul Tambre2021-01-111-1/+1
| | | | | | | | | | | | Bracket arguments are literal and shouldn't be expanded. Fixes #21671.
* | Merge topic 'cpp-modules'Brad King2021-01-071-3/+4
|\ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 39cbbb59a5 ninja: add experimental infrastructure to generate gcc-format modmap files 791b4d26d6 ninja: add experimental infrastructure to generate modmap files with dyndep 4b23359117 ninja: Add experimental infrastructure for C++20 module dependency scanning f814d3b3c6 cmNinjaTargetGenerator: use $OBJ_FILE for the object b0fc2993e1 Treat the '.mpp' file extension as C++ code 988f997100 cmScanDepFormat: Fix name of our internal tool in parse errors dacd93a2db ninja: De-duplicate version numbers required for ninja features 533386ca29 cmStandardLevelResolver: Factor out helper to capture stoi exceptions Acked-by: Kitware Robot <kwrobot@kitware.com> Acked-by: Ben Boeckel <ben.boeckel@kitware.com> Acked-by: Robert Maynard <robert.maynard@kitware.com> Acked-by: Shannon Booth <shannon.ml.booth@gmail.com> Merge-request: !5562