1
0
mirror of https://github.com/Kitware/CMake.git synced 2025-10-15 20:46:37 +08:00

ccmake: Don't list --preset in --help

And show available options in cmake-gui.

Fixes: #21313
This commit is contained in:
Kyle Edwards
2020-10-26 12:00:38 -04:00
parent 8d6a0b9364
commit c619be2784
3 changed files with 8 additions and 3 deletions

View File

@@ -36,7 +36,12 @@ static const char* cmDocumentationUsage[][2] = {
{ nullptr, nullptr }
};
static const char* cmDocumentationOptions[][2] = { { nullptr, nullptr } };
static const char* cmDocumentationOptions[][2] = {
{ "-S <path-to-source>", "Explicitly specify a source directory." },
{ "-B <path-to-build>", "Explicitly specify a build directory." },
{ "--preset=<preset>", "Specify a configure preset." },
{ nullptr, nullptr }
};
#if defined(Q_OS_MAC)
static int cmOSXInstall(std::string dir);

View File

@@ -704,8 +704,6 @@ private:
#define CMAKE_STANDARD_OPTIONS_TABLE \
{ "-S <path-to-source>", "Explicitly specify a source directory." }, \
{ "-B <path-to-build>", "Explicitly specify a build directory." }, \
{ "--preset=<preset-name>", "Explicitly specify a preset." }, \
{ "--list-presets", "List available presets." }, \
{ "-C <initial-cache>", "Pre-load a script to populate the cache." }, \
{ "-D <var>[:<type>]=<value>", "Create or update a cmake cache entry." }, \
{ "-U <globbing_expr>", "Remove matching entries from CMake cache." }, \

View File

@@ -64,6 +64,8 @@ const char* cmDocumentationUsageNote[][2] = {
const char* cmDocumentationOptions[][2] = {
CMAKE_STANDARD_OPTIONS_TABLE,
{ "--preset=<preset>", "Specify a configure preset." },
{ "--list-presets", "List available presets." },
{ "-E", "CMake command mode." },
{ "-L[A][H]", "List non-advanced cached variables." },
{ "--build <dir>", "Build a CMake-generated project binary tree." },