Просмотр исходного кода

Guide: Recommend -C for IDE presets instead of -D

Issue: #23083
Kyle Edwards 4 лет назад
Родитель
Сommit
94de63effa
1 измененных файлов с 6 добавлено и 0 удалено
  1. 6 0
      Help/guide/ide-integration/index.rst

+ 6 - 0
Help/guide/ide-integration/index.rst

@@ -65,6 +65,12 @@ run:
 
 
   cmake -S /path/to/source -B /path/to/source/build -G Ninja
   cmake -S /path/to/source -B /path/to/source/build -G Ninja
 
 
+In cases where a preset contains lots of cache variables, and passing all of
+them as ``-D`` flags would cause the command line length limit of the platform
+to be exceeded, the IDE should instead construct a temporary cache script and
+pass it with the ``-C`` flag. See :ref:`CMake Options` for details on how the
+``-C`` flag is used.
+
 While reading, parsing, and evaluating the contents of ``CMakePresets.json`` is
 While reading, parsing, and evaluating the contents of ``CMakePresets.json`` is
 straightforward, it is not trivial. In addition to the documentation, IDE
 straightforward, it is not trivial. In addition to the documentation, IDE
 vendors may also wish to refer to the CMake source code and test cases for a
 vendors may also wish to refer to the CMake source code and test cases for a