Commit Graph

141 Commits

Author SHA1 Message Date
Markus Ferrell
e1f2b35723 Tutorial: Refactor MakeTable commands into MakeTable.cmake 2023-03-07 11:43:26 -05:00
Markus Ferrell
8ddf32196c Tutorial: Refactor MathFunctions code
Propagate the refactor in Step 10 MathFunctions through all of the
steps. Use MathFunctions/MathFunctions.cxx instead of Tutorial.cxx
to determine which sqrt library is called. Adds .h files which
correspond to their .cxx files by name.
2023-02-23 09:42:10 -05:00
Eisuke Kawashima
6d48f48d5d FetchContent: Bump documented example Catch2 to v3.0.1
The previous Catch2 v2.13.4 does not compile on some platforms [1].

[1] https://github.com/catchorg/Catch2/issues/2326
2023-02-07 10:54:25 -05:00
Joshua Perrett
2e3fcf9399 Tutorial: Fix typos in Step 11 exercise and solution 2023-01-18 21:43:49 +00:00
Joshua Perrett
f04c548877 Tutorial: Fix exercise in Step 10 to match solution provided in Step 11
The solution in Step 11 sets POSITION_INDEPENDENT_CODE to
`${BUILD_SHARED_LIBS}`, rather than simply to "True" in all cases.
2023-01-18 21:43:49 +00:00
Joshua Perrett
566e12c976 Tutorial: Fix destination of link from Step 6 to Step 5
The link in Step 6 (to "Testing Support") clearly refers to Exercise 2.
Fix the location to which the link jumps.
2023-01-18 21:43:49 +00:00
Joshua Perrett
bef0b9eb64 Tutorial: Fix exercise in Step 5 to match solution provided in Step 6
If you look at the solution for Step 6, you will see `0.0001` rather
than `0.00001` used for the last test case.  Fix the typo.
2023-01-18 14:10:42 -05:00
Markus Ferrell
91f6c808d0 Tutorial: Fix typo in step 5 todo statement 2023-01-11 11:55:53 -05:00
Alex Turbov
c86ec79d07
Help: Use direct refs to genexes instead of `$<GENEX-NAME>` 2022-11-09 23:52:30 +04:00
Alex Turbov
029210730a
Help: Use role :program:
When mention execitable names use Sphinx semantic role `:program`
instead of ``executable`` or **executable**.
2022-11-06 04:28:21 +04:00
Brad King
6b27854d26 Merge topic 'tutorial_step7_update'
f9ef15f3dc Tutorial: Update step 7 style

Acked-by: Kitware Robot <kwrobot@kitware.com>
Acked-by: buildbot <buildbot@kitware.com>
Merge-request: !7787
2022-10-28 10:03:10 -04:00
Markus Ferrell
43f87741f4 Tutorial: Fix Step 5 solution after update to Step 6
Since commit 6e58a01f4e (Tutorial: Update step 6 style, 2022-10-06) the
`literalinclude` included an extra comment from step 6 instructions.
Fix the include bounds to remove the extra text.
2022-10-27 11:30:46 -04:00
Markus Ferrell
f9ef15f3dc Tutorial: Update step 7 style 2022-10-27 10:08:56 -04:00
Brad King
2954a810ce Merge topic 'tutorial_step6_update'
6e58a01f4e Tutorial: Update step 6 style

Acked-by: Kitware Robot <kwrobot@kitware.com>
Acked-by: buildbot <buildbot@kitware.com>
Merge-request: !7756
2022-10-27 09:45:48 -04:00
Markus Ferrell
277fbb3035 Tutorial: Restore USE_MYMATH in place of MY_MATH
In commit 80f5d28813 (Tutorial: Update step 2 style, 2022-07-25,
v3.25.0-rc1~226^2) we replaced some uses of `USE_MYMATH` with `MY_MATH`.
Restore the former name for consistency with the rest of the tutorial.
2022-10-25 16:31:38 -04:00
Markus Ferrell
6e58a01f4e Tutorial: Update step 6 style 2022-10-25 11:54:05 -04:00
Alex Turbov
3043c17039 Help: Add more CLI :option: references to various pages 2022-10-20 11:21:40 -04:00
Steven
5b7e465be3 Tutorial: Fix variable name typo in step 1
`CMAKE_CXX_REQUIRED_STANDARD` => `CMAKE_CXX_STANDARD_REQUIRED`
2022-10-17 10:36:15 -04:00
Brad King
a546a19385 Merge topic 'tutorial_step5_update'
92edbce342 Tutorial: Update step 5 style

Acked-by: Kitware Robot <kwrobot@kitware.com>
Acked-by: buildbot <buildbot@kitware.com>
Merge-request: !7728
2022-10-07 09:40:16 -04:00
Markus Ferrell
92edbce342 Tutorial: Update step 5 style 2022-10-06 12:08:43 -04:00
Brad King
b768a5e23b Help: Disambiguate cmake(1) program modes in Sphinx option references
Define the entry point to each mode as an option for the `cmake`
program, but reference the options for that mode as part of stand-in
`cmake-<mode>` programs.
2022-10-05 15:27:40 -04:00
Brad King
beb4f5df47 Merge topic 'tutorial_step4_update'
37fceb6fd3 Tutorial: Update step 4 style

Acked-by: Kitware Robot <kwrobot@kitware.com>
Acked-by: buildbot <buildbot@kitware.com>
Merge-request: !7646
2022-09-29 07:54:05 -04:00
Markus Ferrell
37fceb6fd3 Tutorial: Update step 4 style 2022-09-28 11:38:28 -04:00
Hinell
3d31f99b74 Help: Link from usage requirement commands to detailed explanation
Augment vague mentions of "Transitive Usage Requirements" with links to
a detailed explanation.

Fixes: #23799
2022-09-16 10:54:27 -04:00
Markus Ferrell
3241e3ef03 Tutorial: Align step 12 prose with documentation
Fixes: #23918
2022-09-05 10:03:06 -04:00
tocic
83c89cea5a
Help: Fix minor typos in guides 2022-09-04 23:04:49 +10:00
Markus Ferrell
8c3aa7def7 Tutorial: Update step 3 style 2022-08-31 17:41:17 -04:00
Markus Ferrell
80f5d28813 Tutorial: Update step 2 style 2022-08-29 15:43:53 -04:00
Markus Ferrell
953d729622 Tutorial: Collapse step 1 solutions 2022-08-15 12:06:46 -04:00
Markus Ferrell
c59e164155 Tutorial: Add Step 1 background info and update style 2022-08-15 12:06:34 -04:00
Brad King
7e580e48a4 Merge topic 'tutorial_genExp_rearrange'
ccba87b05b Tutorial: Move step 10 to step 4

Acked-by: Kitware Robot <kwrobot@kitware.com>
Acked-by: buildbot <buildbot@kitware.com>
Merge-request: !7506
2022-08-10 09:21:32 -04:00
Markus Ferrell
ccba87b05b Tutorial: Move step 10 to step 4
Shifts steps 4-9 to 5-10.
2022-08-08 17:15:48 -04:00
Alex Turbov
04843d743e Help: Replace a bunch of more `--option to :option:` role 2022-08-04 19:34:45 +04:00
Alex Turbov
b57f27b087 Help: Replace mentions of `-T and -A` options with role 2022-08-04 19:34:45 +04:00
Alex Turbov
d25b232dee Help: Replace mentions of `-G option with :option:-G` role 2022-08-04 19:34:45 +04:00
Alex Turbov
63940e1cab Help: Replace mentions of `-C option with :option:-C` role 2022-08-04 19:34:44 +04:00
Brad King
1cde77e526 Merge topic 'doc-find_package-BYPASS_PROVIDER'
4f7a0c25d2 Help: Document BYPASS_PROVIDER keyword for find_package()
76370e06b8 Help: Minor grammar fix for the Using Dependencies manual

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !7501
2022-07-25 12:02:20 -04:00
Craig Scott
76370e06b8 Help: Minor grammar fix for the Using Dependencies manual 2022-07-23 21:30:53 +10:00
Brad King
1cee9a9012 Merge topic 'tutorial_cdash_rearrange'
6c77ccec51 Tutorial: Move step 8 to step 5. Shift steps 5-7 to 6-8.

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !7480
2022-07-22 10:13:49 -04:00
Markus Ferrell
6c77ccec51 Tutorial: Move step 8 to step 5. Shift steps 5-7 to 6-8. 2022-07-19 15:32:42 -04:00
Markus Ferrell
bc0aef31ee Tutorial: Add reference links for step 1 commands 2022-07-19 13:18:55 -04:00
FeRD (Frank Dana)
8d8d8ac772 Help: Mark features new to 3.24 in Using Dependencies Guide
The sections on FetchContent's FIND_PACKAGE_ARGS and on
Dependency Providers only apply to CMake 3.24+, so add
versionadded markers at the start of both sections.
2022-06-27 13:26:46 -04:00
Craig Scott
92e93f5c9e Help: Overhaul and expand the Using Dependencies Guide
The guide previously only focused on the find_package() command,
with a bias towards libraries. FetchContent was not mentioned at all.
Reorganise and update the existing content. Add new sections to cover
providing dependencies with FetchContent and dependency providers.
Improve discoverability of the guide by mentioning it at the beginning
of the find_package(), FetchContent and dependency provider docs.
2022-06-09 22:55:11 +10:00
Brad King
5c84eca210 Tutorial: Simplify logic checking for cmath functions
Since commit 07223c5c27 (Tutorial: Update Step 5 to work on Windows,
2020-02-18, v3.18.0-rc1~655^2) the logic does not work on non-Windows
platforms when cmake is re-run on an existing build tree.  It is also
more complicated than we'd like for a tutorial example.  Avoid the need
to consider the `m` library case by performing the check as C++.

Since `check_cxx_symbol_exists` cannot handle overloaded functions
like `exp` and `log`, check with `check_cxx_source_compiles` instead.
This also presents a more general-purpose example in the tutorial.

Fixes: #23524
2022-06-01 13:57:47 -04:00
Brad King
4cb616fed6 Tutorial: Provide a source archive when published on cmake.org
Provide readers following the tutorial on `cmake.org` a direct link to
download the tutorial's source examples.  Previously readers had to
fetch the CMake source tree separately and look for the tutorial source
examples inside it.

Fixes: #22475
2022-04-28 13:36:20 -04:00
Martin Duffy
27589da705 Help/guide: Fix wrong header file reference
Step 2 references mysqrt.h instead of MathFunctions.h.
MathFunctions/mysqrt.h doesn't exist until Step 9.
2022-04-21 14:25:06 -04:00
Øystein Sørensen
6892002fcb Tutorial: Fix casing of reference to License.txt
Correct a tiny typo in the Step 7 tutorial.  Change so `License.txt`
correctly starts with a capital `L`.
2022-03-21 15:58:26 -04:00
Connor Imes
5317015e68 Help: use package-specific var for supported component list
Always using `_supported_components` causes conflicts when transitive
dependencies also set this variable, e.g., because the developers
followed these code samples.

An even more general approach could be to set
`_${CMAKE_FIND_PACKAGE_NAME}_supported_components` instead, but such a
change should then be applied to other variables for consistency.

Fixes: #23112
2022-02-14 10:16:52 -05:00
Brad King
6baf3b27c9 Merge topic 'ide_guide'
6a5936c596 Help: Add IDE Integration Guide section on IDEs supporting CMake

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !6851
2022-01-13 15:23:04 -05:00
Semyon Kolton
6a5936c596 Help: Add IDE Integration Guide section on IDEs supporting CMake 2022-01-12 15:48:39 -05:00