Commit Graph

5662 Commits

Author SHA1 Message Date
Kyle Edwards
94de63effa Guide: Recommend -C for IDE presets instead of -D
Issue: #23083
2022-01-07 12:43:53 -05:00
David Wosk
da737d34e0 CPack/productbuild: add options to control domains element
The domains element determines the required authorization level needed
for the install. The auth attribute of the pkg-ref element has been
deprecated in favor of domains, so if the domains options are
specified, the auth attribute is omitted.

Fixes: #23030
2022-01-06 11:33:25 -05:00
Craig Scott
6b170578b8 Help: Non-zero floating point numbers are true in if() expressions
Fixes: #22991
2022-01-04 08:45:23 +11:00
Brad King
138aabfa9d Merge topic 'vs-csharp-dotnet-sdk'
0eea32a376 VS: Add DOTNET_SDK property to generate SDK-style C# projects
a450cc9533 VS: Set ResolveNugetPackages to false for ALL_BUILD and ZERO_CHECK
fa76e5d194 cmVisualStudio10TargetGenerator: Factor out helper for classic MSBuild project

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !6634
2021-12-22 08:56:22 -05:00
Brad King
69eb5b2421 Merge topic 'doc-list-non-existent'
b573a732dc Tests: add tests to check claims in the documentation
b151db01f9 Help: mention non-existent case for list(PREPEND)
b3a249c2cb Help: clarify range for list(INSERT), mention nonexistent / empty case
b6fdcb3df0 Help: clarify description of list(INSERT)
e55f473ea9 Help: clarify that list(APPEND) on a non-existent list creates it

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !6824
2021-12-22 08:53:02 -05:00
Brad King
217f363cac Merge topic 'link-only-targets'
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
2021-12-22 08:52:13 -05:00
Sumit Bhardwaj
0eea32a376 VS: Add DOTNET_SDK property to generate SDK-style C# projects
Changes in cmVisualStudio10TargetGenerator::Generate to write .Net
SDK-style project for VS generators VS 19 and above. Also adds
documentation and tests.

Issue: #20227
2021-12-21 09:35:49 -08:00
Adriaan de Groot
b151db01f9 Help: mention non-existent case for list(PREPEND) 2021-12-21 10:55:43 -05:00
Adriaan de Groot
b3a249c2cb Help: clarify range for list(INSERT), mention nonexistent / empty case 2021-12-21 10:55:35 -05:00
Adriaan de Groot
b6fdcb3df0 Help: clarify description of list(INSERT)
Since the argument is called 'index', use that in the description.
2021-12-21 10:55:32 -05:00
Adriaan de Groot
e55f473ea9 Help: clarify that list(APPEND) on a non-existent list creates it
This is hinted-at in the introduction, which mentions creating
a new variable value in the current scope, but let's make it
explicit.

Fixes: #22910
2021-12-21 10:55:22 -05:00
Brad King
37af6c3311 target_link_libraries: Optionally require only target names
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
2021-12-20 12:14:07 -05:00
Brad King
6fda93faf8 FindGLUT: Provide modern-named GLUT_INCLUDE_DIRS result variable
Previously this module only provided `GLUT_INCLUDE_DIR`, which does not
follow the modern naming convention documented in `cmake-developer(7)`.

Issue: #23018
2021-12-20 09:53:33 -05:00
Brad King
ece1900731 Merge topic 'doc-if-defined'
a45e922768 Help: Clarify behavior of if(DEFINED) for cache and non-cache variables

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !6817
2021-12-20 09:44:43 -05:00
Craig Scott
47168b2231 Help: Clarify CMP0126 OLD behavior for FORCE and INTERNAL
Fixes: #23022
2021-12-20 21:24:50 +11:00
Craig Scott
a45e922768 Help: Clarify behavior of if(DEFINED) for cache and non-cache variables
Fixes: #23023
2021-12-20 19:27:39 +11:00
John Parent
d7b18895bc cmake: Add filtered debug-find options
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
2021-12-17 08:55:21 -05:00
Brad King
74f1fbb7a1 Help/dev: Cover module function naming in CMake Documentation Guide 2021-12-08 17:05:25 -05:00
Brad King
2d4c3cf684 Merge topic 'ifw-sign-installer'
e8e07a90c1 CPackIFW: add support for signing the generated app bundles on macOS

Acked-by: Kitware Robot <kwrobot@kitware.com>
Acked-by: buildbot <buildbot@kitware.com>
Merge-request: !6754
2021-12-02 12:32:01 -05:00
Brad King
29c80aec94 Merge topic 'tutorial-cpack-source-archive'
39c410624a Tutorial: in step 7, disambiguate installed/source archive
44c527bc63 Tutorial: Package only one source archive

Acked-by: Kitware Robot <kwrobot@kitware.com>
Acked-by: buildbot <buildbot@kitware.com>
Merge-request: !6765
2021-12-01 09:47:57 -05:00
Brad King
e73de3b9cc Merge topic 'tutorial-install-arg-order'
4f524797dc Tutorial: Order install(TARGETS) EXPORT option consistently with docs

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !6770
2021-12-01 09:47:08 -05:00
Brad King
1c77801636 Merge topic 'doc-if-basic-expressions'
294581a443 Help: Be more explicit about the behavior of if(<string>)
3a9695557d Help: Explicitly state that if(ENV{some_var}) is always false

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !6768
2021-12-01 09:37:41 -05:00
Craig Scott
294581a443 Help: Be more explicit about the behavior of if(<string>) 2021-12-01 18:59:23 +11:00
Craig Scott
3a9695557d Help: Explicitly state that if(ENV{some_var}) is always false 2021-12-01 18:30:26 +11:00
Joachim Wuttke (h)
39c410624a Tutorial: in step 7, disambiguate installed/source archive 2021-11-30 12:32:12 -05:00
Joachim Wuttke (h)
44c527bc63 Tutorial: Package only one source archive 2021-11-30 12:31:55 -05:00
Joachim Wuttke (h)
4f524797dc Tutorial: Order install(TARGETS) EXPORT option consistently with docs 2021-11-30 12:23:56 -05:00
Brad King
c8f039b77f Merge topic 'doc-CMAKE_INSTALL_MODE'
3caeee0c86 Help: Clarify CMAKE_INSTALL_MODE documentation
699d4a98e2 Help: Use definition list for allowed values of CMAKE_INSTALL_MODE

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !6743
2021-11-30 08:46:12 -05:00
Felix Lelchuk
3caeee0c86 Help: Clarify CMAKE_INSTALL_MODE documentation
Fixes: #22869
Co-Authored-By: Craig Scott <craig.scott@crascit.com>
2021-11-24 08:30:38 +11:00
Craig Scott
699d4a98e2 Help: Use definition list for allowed values of CMAKE_INSTALL_MODE
Clean up the wording as well for improved consistency
and clarity.
2021-11-24 08:20:04 +11:00
Brad King
580e20d0d4 Merge branch 'backport-ci-rename-jobs' into ci-rename-jobs 2021-11-23 10:13:23 -05:00
Ben Boeckel
7d5828e293 gitlab-ci: shorten job prefixes
This helps to maximize the amount of information visible in the GitLab
web interface.

Also document their meaning in the developer documentation and in the CI
configuration file directly.

See: https://gitlab.com/gitlab-org/gitlab/-/issues/8496
2021-11-23 10:11:25 -05:00
Brad King
eaef62ec3b Merge topic 'doc-policy-default'
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
2021-11-23 09:53:43 -05:00
Erlend E. Aasland
e8e07a90c1 CPackIFW: add support for signing the generated app bundles on macOS
Adds the CPACK_IFW_PACKAGE_SIGNING_IDENTITY CPackIFW variable.

This variable mirrors the --sign option of the binarycreator tool.

Fixes: #22927
2021-11-22 23:30:57 +01:00
Brad King
69b70968bd Help: Suggest CMAKE_POLICY_DEFAULT_CMP0126 in CMP0126 docs 2021-11-22 14:57:22 -05:00
Brad King
5b1c24255f Help: Suggest CMAKE_POLICY_DEFAULT_CMP0077 in CMP0077 docs
Issue: #20490
2021-11-22 14:56:17 -05:00
Brad King
c44636a89b Help: Document more use cases for CMAKE_POLICY_DEFAULT_CMPNNNN 2021-11-22 14:55:36 -05:00
Ben Boeckel
c0d8e42a08 gitlab-ci: shorten job prefixes
This helps to maximize the amount of information visible in the GitLab
web interface.

Also document their meaning in the developer documentation and in the CI
configuration file directly.

See: https://gitlab.com/gitlab-org/gitlab/-/issues/8496
2021-11-22 12:58:25 -05:00
Brad King
df123f7d5f Merge topic 'FindGTest-target-for-gmock'
50bf457a0d FindGTest: Add target for gmock library

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !6632
2021-11-22 11:53:19 -05:00
Brad King
86047f75fc Merge topic 'cpack-productbuild-identifier'
7213ceb869 CPack/productbuild: Add option to customize product identifier

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !6738
2021-11-22 11:26:43 -05:00
Eero Aaltonen
50bf457a0d FindGTest: Add target for gmock library
`googlemock` has been absorbed into the
[googletest](https://github.com/google/googletest) project and is built
and installed from the same source tree.

As GTest may be built with or without GMock, skip GMock if it is not
present.

Do not provide result variables for GMock.  They are not provided by
upstream GTest's CMake Package Configuration File.

Also update the test case to cover linking to `GTest::gmock`.
2021-11-22 11:23:39 -05:00
Brad King
51390f0df2 Merge topic 'env-mod-path-list-separator'
71a2c9d31b Help: ENVIRONMENT_MODIFICATION path_list_... separator is based on host

Acked-by: Kitware Robot <kwrobot@kitware.com>
Acked-by: Ben Boeckel <ben.boeckel@kitware.com>
Merge-request: !6753
2021-11-22 11:19:03 -05:00
Craig Scott
71a2c9d31b Help: ENVIRONMENT_MODIFICATION path_list_... separator is based on host
Fixes: #22937
2021-11-21 17:50:29 +11:00
Greg Fiumara
7213ceb869 CPack/productbuild: Add option to customize product identifier
This adds a new option, CPACK_PRODUCTBUILD_IDENTIFIER, which allows
for customization of the productbuild product identifier within the
CPack productbuild generator.

Fixes: #20830
2021-11-18 13:01:35 -05:00
Fred Baksik
ab6f0b51b1 GHS: Add note about -T and path style
If backslashes are used for CMAKE_GENERATOR_TOOLSET, then ctest
processing will complain about COMP0010.

For example:
  Syntax error in cmake code at

    C:/Users/XXX/test_bld/Tests/CTestTestfile.cmake:253

  when parsing string

    C:\Users\XXX\bin_tools\XXX

  Invalid escape sequence \U

  Policy CMP0010 is not set: Bad variable reference syntax is an error.  Run
  "cmake --help-policy CMP0010" for policy details.  Use the cmake_policy
  command to set the policy and suppress this warning.
2021-11-15 13:15:12 -05:00
Fred Baksik
a55b5c4e18 GHS: Update BSP selection logic
Selection of a BSP only needs to be performed if not set by user.

Remove all the logic for printing error and status messages about BSP
selection. These messages also breaks CMake tests.

NOTE: If BSP selection fails then the compiler checks will result in
a build error.  The build error will report that the BSP does not exist.
2021-11-15 13:15:11 -05:00
Fred Baksik
e006b87cc6 GHS: GHSMULTI - Update documentation to match implementation
* The variable being set was named `GHSMULTI` not `GHS-MULTI`.
2021-11-15 13:15:11 -05:00
Fred Baksik
bff48c5908 GHS: Update generator documentation
Break up into different sections and add examples
2021-11-15 13:15:09 -05:00
Brad King
39624cc911 Merge topic 'doc-tests-labels-dynamic'
250acbb099 Help: Improve cross-referencing of test LABELS and related features
a77bdefa3e Help: Add missing version details for Additional Test Measurements

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !6726
2021-11-15 09:24:42 -05:00
Craig Scott
250acbb099 Help: Improve cross-referencing of test LABELS and related features 2021-11-13 20:45:05 +11:00