summaryrefslogtreecommitdiffstats
path: root/Help/policy
Commit message (Collapse)AuthorAgeFilesLines
* Help: Improve wording of FOLDER-related properties and policiesCraig Scott2023-02-251-6/+6
|
* Help: Clarify behavior of BEFORE with target_compile_options()Craig Scott2022-11-271-8/+16
|
* Help: remove links from pages to themselvesBen Boeckel2022-11-181-1/+1
| | | | | At least the top-reference links. Internal `:ref:` usages have been left intact.
* Merge topic 'use_folders_on_by_default'Brad King2022-11-081-0/+30
|\ | | | | | | | | | | | | | | d3acd22380 USE_FOLDERS: Treat as on by default Acked-by: Kitware Robot <kwrobot@kitware.com> Acked-by: Amir Masoud Abdol <amirmasoudabdol@icloud.com> Merge-request: !7830
| * USE_FOLDERS: Treat as on by defaultJuan Ramos2022-11-081-0/+30
| | | | | | | | | | | | | | Add a policy to treat the `USE_FOLDERS` global property as ON by default if it is not set. Fixes: #21695
* | Help: Fix some redirects reported with sphinx linkcheckAlex Turbov2022-11-071-1/+1
|/ | | | Mostly it's about replace `http:` with `https:` protocol.
* Help: Minor grammar, typo and formatting cleanupsCraig Scott2022-10-092-2/+2
|
* Merge topic 'help-add-custom-comman-byproducts'Brad King2022-09-191-0/+3
|\ | | | | | | | | | | | | 00b788e85e Help:custom_command: link policy on BYPRODUCTS Acked-by: Kitware Robot <kwrobot@kitware.com> Merge-request: !7662
| * Help:custom_command: link policy on BYPRODUCTSHinell2022-09-161-0/+3
| | | | | | | | | | | | Link policy explaining BYPRODUCTS. Fixes: #23786
* | Xcode: Do not append per-config suffixes to library search pathsMikko Sivulainen2022-09-151-0/+27
|/ | | | | | | Add policy `CMP0142` to remove the automatic addition of the `$(CONFIGURATION)$(EFFECTIVE_PLATFORM_NAME)` suffix in a compatible way. Fixes: #21757
* MSVC: Add abstraction for debug information formatGlen Chung2022-09-141-0/+55
| | | | | | | | | | | | | | | | 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
* return(): Propagate variables to result scopeMarc Chevrier2022-09-031-0/+17
| | | | Fixes: #23871
* Help: Fix typos, grammar and formatting in CMP0134 policy docsCraig Scott2022-08-301-4/+1
|
* Help: CMP0097 applies to FetchContent as wellCraig Scott2022-07-241-2/+4
| | | | The omission of FetchContent_Declare() in the original policy docs was just an oversight.
* Help: Mention CMP0131 in LINK_LIBRARIES docsCraig Scott2022-07-051-1/+1
|
* CheckIPOSupported: Compile check using flags of calling projectBrad King2022-06-101-1/+19
| | | | | | | | | | | | | | | | Forward `CMAKE_<LANG>_FLAGS` and `CMAKE_<LANG>_FLAGS_DEBUG` from the calling project into the test project. The set of flags may affect the availability of IPO support. Since this may change the result of the check for existing projects, add a policy for compatibility. This was discovered after commit 5fcadc481e (MSVC: Default to -ZI instead of /Zi for x86 and x64, 2022-05-24) introduced policy CMP0138 to switch our default for MSVC's debug info flag. The `-ZI` flag is incompatible with the `-GL` flag used for IPO, so CMP0138 was reverted pending future work on an alternative solution. Re-use the CMP0138 policy number for this change to CheckIPOSupported instead. Fixes: #23607
* MSVC: Revert "Default to -ZI instead of /Zi for x86 and x64"Brad King2022-06-091-31/+1
| | | | | | | | | | | | | | Revert commit 5fcadc481e (MSVC: Default to -ZI instead of /Zi for x86 and x64, 2022-05-24). The `-ZI` flag is incompatible with the `-GL` flag used for IPO, and so is not an unconditionally better default. Revert the change pending future design of a first-class setting for MSVC debug info format that can be automatically reconciled with IPO settings. That commit introduced policy CMP0138, but we already have later policy numbers used too. Leave placeholder text to avoid policy renumbering. Issue: #23607, #10189
* if command: Add PATH_EQUAL operatorMarc Chevrier2022-06-031-0/+17
|
* MSVC: Default to -ZI instead of /Zi for x86 and x64Glen Chung2022-05-261-0/+43
| | | | | | | | | | Add a policy for compatibility. For more information, see [1]. [1] https://docs.microsoft.com/en-us/cpp/build/reference/z7-zi-zi-debug-information-format?view=msvc-170 Fixes: #10189
* try_compile: Add option to skip passing platform variablesBrad King2022-05-161-0/+4
| | | | | | | Add a `CMAKE_TRY_COMPILE_NO_PLATFORM_VARIABLES` variable to tell `try_compile` not to pass platform variables to the test project. Issue: #23219
* try_compile: Propagate platform variables in project-mode tooBrad King2022-05-161-0/+29
| | | | | | | | | Add policy CMP0137 to propagate both our builtin variables and those listed by `CMAKE_TRY_COMPILE_PLATFORM_VARIABLES` to `try_compile` whole-project builds. Inspired-by: Alexander Neumann <Alexander.Neumann@hamburg.de> Fixes: #23219
* OpenWatcom: Support CMAKE_WATCOM_RUNTIME_LIBRARY with Linux and OS/2 buildsCameron Cawley2022-05-061-1/+2
|
* OpenWatcom: Allow specifying the runtime libraryCameron Cawley2022-05-061-0/+49
| | | | | | | | 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
* ExternalProject: Add DOWNLOAD_EXTRACT_TIMESTAMP option and policyKasper Laudrup2022-05-041-0/+29
| | | | | | | | | | Add the option to keep the current filestamps when extracting an archive in ExternalProject_Add. Enabling this option makes the behavior consistent with how ExternalProject_Add is used when checking out code from revision control instead of an archive. Fixes: #22746
* find_* commands: add control over Windows registry viewsMarc Chevrier2022-04-291-0/+39
| | | | Fixes: #22775
* Genex: Add TARGET_BUNDLE_DIR_NAMEBen Leadbetter2022-04-221-0/+1
| | | | | | Evaluate to the name of the bundle directory for a given bundle target. Fixes: #23409
* CPack/DMG: Do not use CPACK_RESOURCE_FILE_LICENSE for SLA by defaultBrad King2022-04-141-0/+32
| | | | | | | | Since macOS 12.0 deprecated the tools needed to attach a SLA to a `.dmg`, we should no longer do this by default. Add a policy to change the default to off. Fixes: #22978
* Merge topic 'doc-CMP0112'Brad King2022-04-041-1/+3
|\ | | | | | | | | | | | | 9993774172 Help: Clarify when policy CMP0112 takes effect Acked-by: Kitware Robot <kwrobot@kitware.com> Merge-request: !7134
| * Help: Clarify when policy CMP0112 takes effectBrad King2022-04-011-1/+3
| | | | | | | | Fixes: #23381
* | CMP0132: Don't set compiler environment variables on first runCraig Scott2022-03-291-0/+26
| | | | | | | | | | | | | | | | | | | | | | When running CMake for the first time in a build tree, for some generators CMake would set compiler environment variables like CC, CXX, etc. when the corresponding language is enabled. That behavior was never documented and can result in different behavior between the first and subsequent runs. Add a policy to no longer set those environment variables. Fixes: #21378
* | LINK_LIBRARIES: Add support for LINK_ONLY genexBrad King2022-03-241-0/+31
| | | | | | | | | | | | | | Previously we always used content guarded by `$<LINK_ONLY:...>` in `LINK_LIBRARIES`, even when evaluating for non-linking usage requirements. Add a policy to honor `LINK_ONLY` in `LINK_LIBRARIES` the same way we already do in `INTERFACE_LINK_LIBRARIES`.
* | while: diagnose errors during condition evaluationBrad King2022-03-041-0/+32
|/ | | | | | Add a policy to diagnose condition errors in a compatible way. Fixes: #23296
* Merge topic 'link-only-targets'Brad King2021-12-221-0/+2
|\ | | | | | | | | | | | | | | | | | | 37af6c3311 target_link_libraries: Optionally require only target names 5134f099a3 cmGeneratorTarget: Factor out message about reasons for a missing target 37a25072ea Tests: Rename RunCMake.{CMP0028 => LinkItemValidation} Acked-by: Kitware Robot <kwrobot@kitware.com> Tested-by: buildbot <buildbot@kitware.com> Merge-request: !6821
| * target_link_libraries: Optionally require only target namesBrad King2021-12-201-0/+2
| | | | | | | | | | | | | | | | | | | | Optionally verify that items in `LINK_LIBRARIES` and `INTERFACE_LINK_LIBRARIES` that can be target names are actually target names. Add a `LINK_LIBRARIES_ONLY_TARGETS` target property and corresponding `CMAKE_LINK_LIBRARIES_ONLY_TARGETS` variable to enable this new check. Fixes: #22858
* | Help: Clarify CMP0126 OLD behavior for FORCE and INTERNALCraig Scott2021-12-201-0/+3
|/ | | Fixes: #23022
* Merge topic 'doc-policy-default'Brad King2021-11-232-2/+7
|\ | | | | | | | | | | | | | | | | 69b70968bd Help: Suggest CMAKE_POLICY_DEFAULT_CMP0126 in CMP0126 docs 5b1c24255f Help: Suggest CMAKE_POLICY_DEFAULT_CMP0077 in CMP0077 docs c44636a89b Help: Document more use cases for CMAKE_POLICY_DEFAULT_CMPNNNN Acked-by: Kitware Robot <kwrobot@kitware.com> Merge-request: !6756
| * Help: Suggest CMAKE_POLICY_DEFAULT_CMP0126 in CMP0126 docsBrad King2021-11-221-1/+4
| |
| * Help: Suggest CMAKE_POLICY_DEFAULT_CMP0077 in CMP0077 docsBrad King2021-11-221-1/+3
| | | | | | | | Issue: #20490
* | Merge topic 'cmp0128-fixup'Brad King2021-11-121-22/+13
|\ \ | |/ | | | | | | | | | | | | e47dfce75d CMP0128: Enable/disable extensions if standard same as default Acked-by: Kitware Robot <kwrobot@kitware.com> Acked-by: buildbot <buildbot@kitware.com> Merge-request: !6723
| * CMP0128: Enable/disable extensions if standard same as defaultRaul Tambre2021-11-111-22/+13
| | | | | | | | | | | | | | | | | | | | | | This was intended to be part of the initial MR (!6177), but accidentally went missing when debugging nightly failures on less common systems. Noticed during !6711 review as the comment about this behaviour didn't match the code. Documentation for CMP0128 is updated to remove a false case and note the two cases related to this. Fixes #22224.
* | Merge topic 'doc-CMP0128'Craig Scott2021-11-101-1/+3
|\ \ | |/ | | | | | | | | | | | | 8371056fbb Help: Correct inaccuracies in wording for CMP0128 Acked-by: Kitware Robot <kwrobot@kitware.com> Reviewed-by: Raul Tambre <raul@tambre.ee> Merge-request: !6711
| * Help: Correct inaccuracies in wording for CMP0128Craig Scott2021-11-081-1/+3
| |
* | LCC: Add policy CMP0129 regarding interpreting LCC as GNUmakise-homura2021-10-211-0/+34
|/ | | | | | | | | | Due to MCST LCC compiler identification is now changed to LCC, there should be a way for old projects to still identify it as GNU, as it was before. This commits adds the policy: CMP0129: Compiler id for MCST LCC compilers is now LCC, not GNU. This policy controls such a behavior. OLD behaivior is to treat LCC as GNU, NEW is to treat is as LCC.
* Help: Update Sphinx versionadded directives for 3.22 releaseBrad King2021-10-071-0/+2
| | | | | | | | | Run the script: Utilities/Sphinx/update_versions.py --since v3.21.0 --overwrite Manually select updates that really belong to the 3.22 release, as against adding documentation for previously-existing entities.
* cmStandardLevelResolver: Avoid unnecessary flags, fix unset level logicRaul Tambre2021-09-291-0/+78
| | | | | | | | | | | | | | | | | | The changes are part of CMP0128. When the standard level is unset: * Flags are added if extension mode doesn't match the compiler's default. Previously logic only worked if LANG_EXTENSIONS was ON. Fixes #22224. * The full flag is used. Previously CMAKE_LANG_EXTENSION_COMPILE_OPTION was used. This was only supported for IAR. Otherwise: * Avoid adding flags if not necessary per the detected compiler defaults. * Fixed check for when the requested standard is older. It now matches the nearby comments. I reworded the fallback comment as its logic was a bit difficult to wrap my head around.
* CMakeDependentOption: Introduce policy CMP0127 for full Condition SyntaxDaniel Schürmann2021-09-101-0/+32
| | | | Fixes: #22303
* Help: Make policy CMP0126 wording more accurate Craig Scott2021-07-172-7/+20
| | | | | | | | | The OLD behavior only removes a non-cache variable of the same name in specific circumstances. The previous wording implied that it would always occur. Also add a note about the behavior compared to the analogous CMP0077 policy, which affects the option() command in a similar but subtly different way.
* Help: Explain policy CMP0125 in more detailCraig Scott2021-07-171-12/+29
|
* Help: Clarify wording of CMP0124Craig Scott2021-07-171-7/+5
|
* CMP0126: Add control for warningsMarc Chevrier2021-06-291-1/+3
| | | | Fixes: #22353