You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@kudu.apache.org by mp...@apache.org on 2017/11/08 18:59:09 UTC
kudu git commit: Suppress -Wcomment compiler warnings
Repository: kudu
Updated Branches:
refs/heads/master 28fdec405 -> b02252ad5
Suppress -Wcomment compiler warnings
We have a bunch of annoying warnings in otherwise-normal g++ builds.
Let's get rid of these unnecessary warnings. Examples:
[765/1328] Building CXX object src/kudu/util/CMakeFiles/interval_tree-test.dir/interval_tree-test.cc.o
In file included from ../../src/kudu/util/interval_tree-test.cc:37:0:
../../src/kudu/util/interval_tree-inl.h:269:3: warning: multi-line comment [-Wcomment]
// [------] \
^
../../src/kudu/util/interval_tree-inl.h:308:3: warning: multi-line comment [-Wcomment]
// [--------] \
^
[943/1328] Building CXX object src/kudu/server/CMakeFiles/server_process.dir/webserver.cc.o
../../src/kudu/server/webserver.cc:360:5: warning: multi-line comment [-Wcomment]
// https://github.com/cloudera/squeasel/blob/\
^
[995/1328] Building CXX object src/kudu/tablet/CMakeFiles/tablet.dir/rowset_tree.cc.o
In file included from ../../src/kudu/tablet/rowset_tree.cc:33:0:
../../src/kudu/util/interval_tree-inl.h:269:3: warning: multi-line comment [-Wcomment]
// [------] \
^
../../src/kudu/util/interval_tree-inl.h:308:3: warning: multi-line comment [-Wcomment]
// [--------] \
^
[1218/1328] Building CXX object src/kudu/tools/CMakeFiles/kudu.dir/tool_action_perf.cc.o
../../src/kudu/tools/tool_action_perf.cc:33:1: warning: multi-line comment [-Wcomment]
// kudu perf loadgen \
^
../../src/kudu/tools/tool_action_perf.cc:49:1: warning: multi-line comment [-Wcomment]
// kudu perf loadgen \
^
../../src/kudu/tools/tool_action_perf.cc:65:1: warning: multi-line comment [-Wcomment]
// kudu perf loadgen \
^
../../src/kudu/tools/tool_action_perf.cc:82:1: warning: multi-line comment [-Wcomment]
// kudu perf loadgen \
^
../../src/kudu/tools/tool_action_perf.cc:94:1: warning: multi-line comment [-Wcomment]
// kudu perf loadgen 127.0.0.1 --table_name=t3 --num_threads=2 \
^
../../src/kudu/tools/tool_action_perf.cc:97:1: warning: multi-line comment [-Wcomment]
// kudu perf loadgen 127.0.0.1 --table_name=t3 --num_threads=2 \
^
../../src/kudu/tools/tool_action_perf.cc:100:1: warning: multi-line comment [-Wcomment]
// perf perf loadgen 127.0.0.1 --table_name=t3 --num_threads=2 \
^
Change-Id: Ic320fa11a6f67ed107b1fff2b1f2da7f7bd39cd0
Reviewed-on: http://gerrit.cloudera.org:8080/8495
Reviewed-by: Alexey Serbin <as...@cloudera.com>
Tested-by: Kudu Jenkins
Project: http://git-wip-us.apache.org/repos/asf/kudu/repo
Commit: http://git-wip-us.apache.org/repos/asf/kudu/commit/b02252ad
Tree: http://git-wip-us.apache.org/repos/asf/kudu/tree/b02252ad
Diff: http://git-wip-us.apache.org/repos/asf/kudu/diff/b02252ad
Branch: refs/heads/master
Commit: b02252ad5a8cfc3895c4856e3256c57d76d2cc4e
Parents: 28fdec4
Author: Mike Percy <mp...@apache.org>
Authored: Tue Nov 7 20:33:57 2017 -0800
Committer: Mike Percy <mp...@apache.org>
Committed: Wed Nov 8 18:58:57 2017 +0000
----------------------------------------------------------------------
CMakeLists.txt | 14 +++++++++-----
1 file changed, 9 insertions(+), 5 deletions(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/kudu/blob/b02252ad/CMakeLists.txt
----------------------------------------------------------------------
diff --git a/CMakeLists.txt b/CMakeLists.txt
index 587d700..d6ee5b6 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -123,17 +123,21 @@ endif()
############################################################
# compiler flags that are common across debug/release builds
-# - msse4.2: Enable sse4.2 compiler intrinsics.
+# -msse4.2: Enable sse4.2 compiler intrinsics.
set(CXX_COMMON_FLAGS "-msse4.2")
-# - Wall: Enable all warnings.
+# -Wall: Enable all warnings.
set(CXX_COMMON_FLAGS "${CXX_COMMON_FLAGS} -Wall")
-# - Wno-sign-compare: suppress warnings for comparison between signed and unsigned
-# integers
+# -Wno-sign-compare: suppress warnings for comparison between signed and unsigned
+# integers
set(CXX_COMMON_FLAGS "${CXX_COMMON_FLAGS} -Wno-sign-compare")
+# -Wno-comment: suppress warnings about backslash-newline in "//" comments,
+# which appear in the Kudu source code due to the use of ASCII art and
+# multi-line command line examples in comments.
+set(CXX_COMMON_FLAGS "${CXX_COMMON_FLAGS} -Wno-comment")
# -Wno-deprecated: we currently have a number of places using deprecated functions
# (mostly our own functions). TODO(todd) remove or individually suppress call sites.
set(CXX_COMMON_FLAGS "${CXX_COMMON_FLAGS} -Wno-deprecated")
-# - pthread: enable multithreaded malloc
+# -pthread: enable multithreaded malloc
set(CXX_COMMON_FLAGS "${CXX_COMMON_FLAGS} -pthread")
# -fno-strict-aliasing
# Assume programs do not follow strict aliasing rules.