summaryrefslogtreecommitdiffstats
path: root/Source/CPack/cpack.cxx
diff options
context:
space:
mode:
authorCraig Scott <craig.scott@crascit.com>2019-07-13 00:25:50 (GMT)
committerKitware Robot <kwrobot@kitware.com>2019-07-13 00:26:12 (GMT)
commita2319c04f6c6b881b2cd37ec33378c4781f415e1 (patch)
tree8bb139497bf6493e52acdb1f909d0bcf6178d268 /Source/CPack/cpack.cxx
parent8212b0880d4b481496306535b58adcd9121fd71b (diff)
parentaf75ab7645545bc046d18c8af48f3198a9de4080 (diff)
downloadCMake-a2319c04f6c6b881b2cd37ec33378c4781f415e1.zip
CMake-a2319c04f6c6b881b2cd37ec33378c4781f415e1.tar.gz
CMake-a2319c04f6c6b881b2cd37ec33378c4781f415e1.tar.bz2
Merge topic 'cleanup-statics-stream-flush'
af75ab7645 Refactor: Use anonymous namespace instead of `static`s in `cpack.cxx` 0db458a0ce Refactor: Use anonymous namespace instead of `static`s 0328b64efd Refactor: Remove one-time used macros b821f9ad62 Refactor: Optimize some stream output operations Acked-by: Kitware Robot <kwrobot@kitware.com> Merge-request: !3535
Diffstat (limited to 'Source/CPack/cpack.cxx')
-rw-r--r--Source/CPack/cpack.cxx10
1 files changed, 6 insertions, 4 deletions
diff --git a/Source/CPack/cpack.cxx b/Source/CPack/cpack.cxx
index 67b7ea6..c6018cf 100644
--- a/Source/CPack/cpack.cxx
+++ b/Source/CPack/cpack.cxx
@@ -28,19 +28,20 @@
#include "cmSystemTools.h"
#include "cmake.h"
-static const char* cmDocumentationName[][2] = {
+namespace {
+const char* cmDocumentationName[][2] = {
{ nullptr, " cpack - Packaging driver provided by CMake." },
{ nullptr, nullptr }
};
-static const char* cmDocumentationUsage[][2] = {
+const char* cmDocumentationUsage[][2] = {
// clang-format off
{ nullptr, " cpack [options]" },
{ nullptr, nullptr }
// clang-format on
};
-static const char* cmDocumentationOptions[][2] = {
+const char* cmDocumentationOptions[][2] = {
{ "-G <generators>", "Override/define CPACK_GENERATOR" },
{ "-C <Configuration>", "Specify the project configuration" },
{ "-D <var>=<value>", "Set a CPack variable." },
@@ -89,10 +90,11 @@ int cpackDefinitionArgument(const char* argument, const char* cValue,
return 1;
}
-static void cpackProgressCallback(const std::string& message, float /*unused*/)
+void cpackProgressCallback(const std::string& message, float /*unused*/)
{
std::cout << "-- " << message << std::endl;
}
+} // namespace
// this is CPack.
int main(int argc, char const* const* argv)