summaryrefslogtreecommitdiffstats
path: root/Help/manual/cmake.1.rst
diff options
context:
space:
mode:
Diffstat (limited to 'Help/manual/cmake.1.rst')
-rw-r--r--Help/manual/cmake.1.rst32
1 files changed, 15 insertions, 17 deletions
diff --git a/Help/manual/cmake.1.rst b/Help/manual/cmake.1.rst
index b581e48..7efe0cd 100644
--- a/Help/manual/cmake.1.rst
+++ b/Help/manual/cmake.1.rst
@@ -12,7 +12,6 @@ Synopsis
cmake [<options>] <path-to-source>
cmake [<options>] <path-to-existing-build>
cmake [<options>] -S <path-to-source> -B <path-to-build>
- cmake [<options>] -S <path-to-source> --preset=<preset-name>
`Build a Project`_
cmake --build <dir> [<options>] [-- <build-tool-options>]
@@ -149,22 +148,6 @@ source and build trees and generate a buildsystem:
$ cmake -S src -B build
-``cmake [<options>] -S <path-to-source> --preset=<preset-name>``
- Uses ``<path-to-source>`` as the source tree and reads a
- :manual:`preset <cmake-presets(7)>` from
- ``<path-to-source>/CMakePresets.json`` and
- ``<path-to-source>/CMakeUserPresets.json``. The preset specifies the
- generator and the build directory, and optionally a list of variables and
- other arguments to pass to CMake. The :manual:`CMake GUI <cmake-gui(1)>` can
- also recognize ``CMakePresets.json`` and ``CMakeUserPresets.json`` files. For
- full details on these files, see :manual:`cmake-presets(7)`.
-
- The presets are read before all other command line options. The options
- specified by the preset (variables, generator, etc.) can all be overridden by
- manually specifying them on the command line. For example, if the preset sets
- a variable called ``MYVAR`` to ``1``, but the user sets it to ``2`` with a
- ``-D`` argument, the value ``2`` is preferred.
-
In all cases the ``<options>`` may be zero or more of the `Options`_ below.
After generating a buildsystem one may use the corresponding native
@@ -394,6 +377,21 @@ Options
about:tracing tab of Google Chrome or using a plugin for a tool like Trace
Compass.
+``--preset=<preset>``
+ Reads a :manual:`preset <cmake-presets(7)>` from
+ ``<path-to-source>/CMakePresets.json`` and
+ ``<path-to-source>/CMakeUserPresets.json``. The preset specifies the
+ generator and the build directory, and optionally a list of variables and
+ other arguments to pass to CMake. The :manual:`CMake GUI <cmake-gui(1)>` can
+ also recognize ``CMakePresets.json`` and ``CMakeUserPresets.json`` files. For
+ full details on these files, see :manual:`cmake-presets(7)`.
+
+ The presets are read before all other command line options. The options
+ specified by the preset (variables, generator, etc.) can all be overridden by
+ manually specifying them on the command line. For example, if the preset sets
+ a variable called ``MYVAR`` to ``1``, but the user sets it to ``2`` with a
+ ``-D`` argument, the value ``2`` is preferred.
+
.. _`Build Tool Mode`:
Build a Project