correct documentation about `cmake --build` with targets

This commit is contained in:
Axel Kohlmeyer 2020-05-26 12:26:44 -04:00
parent 5e3fe19756
commit 31a3e84950
No known key found for this signature in database
GPG Key ID: D9B44E93BF0C375A
1 changed files with 5 additions and 3 deletions

View File

@ -415,8 +415,10 @@ This is particularly convenient, if you have set a custom build command
via the ``CMAKE_MAKE_PROGRAM`` variable.
When calling the build program, you can also select which "target" is to
be build through appending the name of the target to the build command.
Example: ``cmake --build . all``. The following abstract targets are available:
be build through appending the ``--target`` flag and the name of the target
to the build command. When using ``make`` as build tool, you can just append
the target name to the command. Example: ``cmake --build . --target all`` or
``make all``. The following abstract targets are available:
.. list-table::
:header-rows: 1
@ -432,7 +434,7 @@ Example: ``cmake --build . all``. The following abstract targets are available:
* - ``install``
- install all target files into folders in ``CMAKE_INSTALL_PREFIX``
* - ``test``
- run some simple tests (if configured with ``-D ENABLE_TESTING=on``)
- run some tests (if configured with ``-D ENABLE_TESTING=on``)
* - ``clean``
- remove all generated files