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 2015/09/28 01:27:55 UTC
[16/20] mesos git commit: CMake: Transitioned Stout tests to use new
third-party build scripts.
CMake: Transitioned Stout tests to use new third-party build scripts.
Review: https://reviews.apache.org/r/38753
Project: http://git-wip-us.apache.org/repos/asf/mesos/repo
Commit: http://git-wip-us.apache.org/repos/asf/mesos/commit/09f9b537
Tree: http://git-wip-us.apache.org/repos/asf/mesos/tree/09f9b537
Diff: http://git-wip-us.apache.org/repos/asf/mesos/diff/09f9b537
Branch: refs/heads/master
Commit: 09f9b5379022fccd5db50ba5ade1ec96882a1fc0
Parents: 81f86c5
Author: Alex Clemmer <cl...@gmail.com>
Authored: Sun Sep 27 15:41:32 2015 -0700
Committer: Joris Van Remoortere <jo...@gmail.com>
Committed: Sun Sep 27 16:21:19 2015 -0700
----------------------------------------------------------------------
.../stout/cmake/StoutTestsConfigure.cmake | 74 +++++---------------
1 file changed, 19 insertions(+), 55 deletions(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/mesos/blob/09f9b537/3rdparty/libprocess/3rdparty/stout/cmake/StoutTestsConfigure.cmake
----------------------------------------------------------------------
diff --git a/3rdparty/libprocess/3rdparty/stout/cmake/StoutTestsConfigure.cmake b/3rdparty/libprocess/3rdparty/stout/cmake/StoutTestsConfigure.cmake
index 0832529..c4d1b7b 100644
--- a/3rdparty/libprocess/3rdparty/stout/cmake/StoutTestsConfigure.cmake
+++ b/3rdparty/libprocess/3rdparty/stout/cmake/StoutTestsConfigure.cmake
@@ -55,39 +55,28 @@ set(STOUT_TEST_DEPENDENCIES
)
if (WIN32)
- set(STOUT_TEST_DEPENDENCIES
- ${STOUT_TEST_DEPENDENCIES}
- ${CURL_TARGET}
- )
-endif(WIN32)
+ set(STOUT_TEST_DEPENDENCIES ${STOUT_TEST_DEPENDENCIES} ${CURL_TARGET})
+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_TEST_INCLUDE_DIRS
${STOUT_TEST_INCLUDE_DIRS}
- ${STOUT}/include
- ${BOOST_ROOT}
- ${PICOJSON_ROOT}
+ ${STOUT_INCLUDE_DIR}
+ ${BOOST_INCLUDE_DIR}
+ ${PICOJSON_INCLUDE_DIR}
${APR_INCLUDE_DIR}
${SVN_INCLUDE_DIR}
- ${GMOCK_ROOT}/include
- ${GTEST_SRC}/include
- ${PROTOBUF_LIB}/include
+ ${GMOCK_INCLUDE_DIR}
+ ${GTEST_INCLUDE_DIR}
+ ${PROTOBUF_INCLUDE_DIR}
src
+ ${GLOG_INCLUDE_DIR}
)
if (WIN32)
- set(STOUT_TEST_INCLUDE_DIRS
- ${STOUT_TEST_INCLUDE_DIRS}
- ${GLOG_ROOT}/src/windows
- ${CURL_ROOT}/include
- )
-else (WIN32)
- set(STOUT_TEST_INCLUDE_DIRS
- ${STOUT_TEST_INCLUDE_DIRS}
- ${GLOG_LIB}/include
- )
+ set(STOUT_TEST_INCLUDE_DIRS ${STOUT_TEST_INCLUDE_DIRS} ${CURL_INCLUDE_DIR})
endif (WIN32)
# DEFINE THIRD-PARTY LIB INSTALL DIRECTORIES. Used to tell the compiler
@@ -98,29 +87,14 @@ set(STOUT_TEST_LIB_DIRS
${STOUT_TEST_LIB_DIRS}
${APR_LIBS}
${SVN_LIBS}
- ${GMOCK_ROOT}-build/lib/.libs
+ ${GMOCK_LIB_DIR}
${GMOCK_ROOT}-build/gtest/lib/.libs
+ ${GLOG_LIB_DIR}
+ ${PROTOBUF_LIB_DIR}
)
if (WIN32)
- # TODO(hausdorff): currently these dependencies have to be built out-of-band
- # by opening Visual Studio, building the project, and then building Mesos. We
- # should write batch scripts that will build these dependencies from the
- # command line. (This is one reason why we're linking to the Debug/ folders,
- # which is not a good idea for release builds anyway.)
- set(STOUT_TEST_LIB_DIRS
- ${STOUT_TEST_LIB_DIRS}
- ${GLOG_ROOT}/Debug
- ${GMOCK_ROOT}/msvc/2010/Debug
- ${PROTOBUF_ROOT}/vsprojects/Debug
- ${CURL_ROOT}/lib
- )
-else (WIN32)
- set(STOUT_TEST_LIB_DIRS
- ${STOUT_TEST_LIB_DIRS}
- ${GLOG_LIB}/lib
- ${PROTOBUF_LIB}/lib
- )
+ set(STOUT_TEST_LIB_DIRS ${STOUT_TEST_LIB_DIRS} ${CURL_LIB_DIR})
endif (WIN32)
# DEFINE THIRD-PARTY LIBS. Used to generate flags that the linker uses to
@@ -129,28 +103,18 @@ endif (WIN32)
set(STOUT_TEST_LIBS
${STOUT_TEST_LIBS}
${CMAKE_THREAD_LIBS_INIT}
- gmock
+ ${GMOCK_LFLAG}
${SVN_LIBS}
+ ${GLOG_LFLAG}
+ ${PROTOBUF_LFLAG}
)
if (WIN32)
- # Necessary because the lib names for glog and protobuf are generated
- # incorrectly on Windows. That is, on *nix, the glog binary should be (e.g.)
- # libglog.so, and on Windows it should be glog.lib. But on Windows, it's
- # actually libglog.lib. Hence, we have to special case it here because CMake
- # assumes the library names are generated correctly.
- set(STOUT_TEST_LIBS
- ${STOUT_TEST_LIBS}
- libglog
- libprotobuf
- libcurl_a
- )
+ set(STOUT_TEST_LIBS ${STOUT_TEST_LIBS} ${CURL_LFLAG})
else (WIN32)
set(STOUT_TEST_LIBS
${STOUT_TEST_LIBS}
- glog
- gtest
- protobuf
+ ${GTEST_LFLAG}
dl
apr-1
)