From 0328b64efdf102206e855d16cd9b765f268c6bc9 Mon Sep 17 00:00:00 2001 From: Alex Turbov Date: Thu, 4 Jul 2019 22:44:44 +0300 Subject: Refactor: Remove one-time used macros Signed-off-by: Alex Turbov --- Source/cmakemain.cxx | 61 ++++++++++++++++++++++++++-------------------------- 1 file changed, 30 insertions(+), 31 deletions(-) diff --git a/Source/cmakemain.cxx b/Source/cmakemain.cxx index f80829f..4f088a8 100644 --- a/Source/cmakemain.cxx +++ b/Source/cmakemain.cxx @@ -54,34 +54,6 @@ static const char* cmDocumentationUsageNote[][2] = { { nullptr, nullptr } }; -# define CMAKE_BUILD_OPTIONS \ - " = Project binary directory to be built.\n" \ - " --parallel [], -j []\n" \ - " = Build in parallel using the given number of jobs. \n" \ - " If is omitted the native build tool's \n" \ - " default number is used.\n" \ - " The CMAKE_BUILD_PARALLEL_LEVEL environment " \ - "variable\n" \ - " specifies a default parallel level when this " \ - "option\n" \ - " is not given.\n" \ - " --target ..., -t ... \n" \ - " = Build instead of default targets.\n" \ - " --config = For multi-configuration tools, choose .\n" \ - " --clean-first = Build target 'clean' first, then build.\n" \ - " (To clean only, use --target 'clean'.)\n" \ - " --verbose, -v = Enable verbose output - if supported - including\n" \ - " the build commands to be executed. \n" \ - " -- = Pass remaining options to the native tool.\n" - -# define CMAKE_INSTALL_OPTIONS \ - " = Project binary directory to install.\n" \ - " --config = For multi-configuration tools, choose .\n" \ - " --component = Component-based install. Only install .\n" \ - " --prefix = The installation prefix CMAKE_INSTALL_PREFIX.\n" \ - " --strip = Performing install/strip.\n" \ - " -v --verbose = Enable verbose output.\n" - static const char* cmDocumentationOptions[][2] = { CMAKE_STANDARD_OPTIONS_TABLE, { "-E", "CMake command mode." }, @@ -539,7 +511,24 @@ static int do_build(int ac, char const* const* av) std::cerr << "Usage: cmake --build [options] [-- [native-options]]\n" "Options:\n" - CMAKE_BUILD_OPTIONS + " = Project binary directory to be built.\n" + " --parallel [], -j []\n" + " = Build in parallel using the given number of jobs. \n" + " If is omitted the native build tool's \n" + " default number is used.\n" + " The CMAKE_BUILD_PARALLEL_LEVEL environment " + "variable\n" + " specifies a default parallel level when this " + "option\n" + " is not given.\n" + " --target ..., -t ... \n" + " = Build instead of default targets.\n" + " --config = For multi-configuration tools, choose .\n" + " --clean-first = Build target 'clean' first, then build.\n" + " (To clean only, use --target 'clean'.)\n" + " --verbose, -v = Enable verbose output - if supported - including\n" + " the build commands to be executed. \n" + " -- = Pass remaining options to the native tool.\n" ; /* clang-format on */ return 1; @@ -625,8 +614,18 @@ static int do_install(int ac, char const* const* av) } if (dir.empty()) { - std::cerr << "Usage: cmake --install " - "[options]\nOptions:\n" CMAKE_INSTALL_OPTIONS; + /* clang-format off */ + std::cerr << + "Usage: cmake --install [options]\n" + "Options:\n" + " = Project binary directory to install.\n" + " --config = For multi-configuration tools, choose .\n" + " --component = Component-based install. Only install .\n" + " --prefix = The installation prefix CMAKE_INSTALL_PREFIX.\n" + " --strip = Performing install/strip.\n" + " -v --verbose = Enable verbose output.\n" + ; + /* clang-format on */ return 1; } -- cgit v0.12