You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@mesos.apache.org by jo...@apache.org on 2017/01/28 02:15:57 UTC

[02/11] mesos git commit: CMake: Marked 3rdparty headers as "system" headers.

CMake: Marked 3rdparty headers as "system" headers.

Because we pull in and build against 3rdparty libraries, we also pull
in the warnings from these 3rdparty libraries.  In most cases, these
warnings can only be addressed by updating the 3rdparty source.

Trivial warnings can be eliminated simply by marking 3rdparty
libraries as `SYSTEM` headers when we specify the include path.

This commit will thus separate out the headers of Stout's 3rdparty
libraries from the Stout API headers, and include them as
`SYSTEM` headers.

Review: https://reviews.apache.org/r/55694/


Project: http://git-wip-us.apache.org/repos/asf/mesos/repo
Commit: http://git-wip-us.apache.org/repos/asf/mesos/commit/8e85a070
Tree: http://git-wip-us.apache.org/repos/asf/mesos/tree/8e85a070
Diff: http://git-wip-us.apache.org/repos/asf/mesos/diff/8e85a070

Branch: refs/heads/master
Commit: 8e85a070d66b74543fddef62bbf826864c204ddc
Parents: fa38172
Author: Alex Clemmer <cl...@gmail.com>
Authored: Fri Jan 27 16:41:57 2017 -0800
Committer: Joseph Wu <jo...@apache.org>
Committed: Fri Jan 27 18:15:41 2017 -0800

----------------------------------------------------------------------
 3rdparty/stout/cmake/StoutConfigure.cmake      | 15 +++++++++------
 3rdparty/stout/cmake/StoutTestsConfigure.cmake |  6 +++---
 3rdparty/stout/tests/CMakeLists.txt            |  3 ++-
 3 files changed, 14 insertions(+), 10 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/mesos/blob/8e85a070/3rdparty/stout/cmake/StoutConfigure.cmake
----------------------------------------------------------------------
diff --git a/3rdparty/stout/cmake/StoutConfigure.cmake b/3rdparty/stout/cmake/StoutConfigure.cmake
index b275546..32ce8c7 100644
--- a/3rdparty/stout/cmake/StoutConfigure.cmake
+++ b/3rdparty/stout/cmake/StoutConfigure.cmake
@@ -71,9 +71,8 @@ endif (WIN32)
 # DEFINE THIRD-PARTY INCLUDE DIRECTORIES. Tells compiler toolchain where to get
 # headers for our third party libs (e.g., -I/path/to/glog on Linux).
 ###############################################################################
-set(STOUT_INCLUDE_DIRS
-  ${STOUT_INCLUDE_DIRS}
-  ${STOUT_INCLUDE_DIR}
+set(STOUT_3RDPARTY_INCLUDE_DIRS
+  ${STOUT_3RDPARTY_INCLUDE_DIRS}
   ${APR_INCLUDE_DIR}
   ${BOOST_INCLUDE_DIR}
   ${ELFIO_INCLUDE_DIR}
@@ -82,17 +81,21 @@ set(STOUT_INCLUDE_DIRS
   ${PICOJSON_INCLUDE_DIR}
   ${PROTOBUF_INCLUDE_DIR}
   ${SVN_INCLUDE_DIR}
-  src
   )
 
 if (WIN32)
-  set(STOUT_INCLUDE_DIRS
-    ${STOUT_INCLUDE_DIRS}
+  set(STOUT_3RDPARTY_INCLUDE_DIRS
+    ${STOUT_3RDPARTY_INCLUDE_DIRS}
     ${CURL_INCLUDE_DIR}
     ${ZLIB_INCLUDE_DIR}
     )
 endif (WIN32)
 
+set(STOUT_INCLUDE_DIRS
+  ${STOUT_INCLUDE_DIRS}
+  ${STOUT_INCLUDE_DIR}
+  )
+
 # DEFINE THIRD-PARTY LIB INSTALL DIRECTORIES. Used to tell the compiler
 # toolchain where to find our third party libs (e.g., -L/path/to/glog on
 # Linux).

http://git-wip-us.apache.org/repos/asf/mesos/blob/8e85a070/3rdparty/stout/cmake/StoutTestsConfigure.cmake
----------------------------------------------------------------------
diff --git a/3rdparty/stout/cmake/StoutTestsConfigure.cmake b/3rdparty/stout/cmake/StoutTestsConfigure.cmake
index d3bd72e..685f1c8 100644
--- a/3rdparty/stout/cmake/StoutTestsConfigure.cmake
+++ b/3rdparty/stout/cmake/StoutTestsConfigure.cmake
@@ -77,9 +77,9 @@ set(STOUT_TEST_DEPENDENCIES
 # DEFINE THIRD-PARTY INCLUDE DIRECTORIES. Tells compiler toolchain where to get
 # headers for our third party libs (e.g., -I/path/to/glog on Linux)..
 ###############################################################################
-set(STOUT_TEST_INCLUDE_DIRS
-  ${STOUT_TEST_INCLUDE_DIRS}
-  ${STOUT_INCLUDE_DIRS}
+set(STOUT_TEST_3RDPARTY_INCLUDE_DIRS
+  ${STOUT_TEST_3RDPARTY_INCLUDE_DIRS}
+  ${STOUT_3RDPARTY_INCLUDE_DIRS}
   ${GMOCK_INCLUDE_DIR}
   ${GTEST_INCLUDE_DIR}
   )

http://git-wip-us.apache.org/repos/asf/mesos/blob/8e85a070/3rdparty/stout/tests/CMakeLists.txt
----------------------------------------------------------------------
diff --git a/3rdparty/stout/tests/CMakeLists.txt b/3rdparty/stout/tests/CMakeLists.txt
index 617be02..4e22bf6 100644
--- a/3rdparty/stout/tests/CMakeLists.txt
+++ b/3rdparty/stout/tests/CMakeLists.txt
@@ -96,7 +96,8 @@ set(STOUT_TESTS_SRC
 # INCLUDE DIRECTIVES FOR STOUT TEST BINARY (generates, e.g., -I/path/to/thing
 # on Linux).
 #############################################################################
-include_directories(${STOUT_TEST_INCLUDE_DIRS})
+include_directories(SYSTEM ${STOUT_TEST_3RDPARTY_INCLUDE_DIRS})
+include_directories(${STOUT_INCLUDE_DIRS})
 
 # LINKING LIBRARIES BY DIRECTORY (might generate, e.g., -L/path/to/thing on
 # Linux).