mesos-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From jo...@apache.org
Subject [13/20] mesos git commit: CMake: Added Windows-specific build targets for APR.
Date Sun, 27 Sep 2015 23:27:52 GMT
CMake: Added Windows-specific build targets for APR.

APR is required for Mesos to run. Normally we expect that a user has
obtained APR with their favorite package manager, but on Windows, we
cannot really expect that this is the case. So, we have to rope in the
dependency manually in the CMake build system.

This commit will introduce the necessary build targets to obtain,
configure, build, and install APR for Windows builds. It will ignore APR
and assume it's there for Linux builds.

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


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

Branch: refs/heads/master
Commit: 868e7878741a1063ee068bf7d7b6a0d668508c32
Parents: 9f4d76c
Author: Alex Clemmer <clemmer.alexander@gmail.com>
Authored: Sun Sep 27 15:41:28 2015 -0700
Committer: Joris Van Remoortere <joris.van.remoortere@gmail.com>
Committed: Sun Sep 27 16:16:49 2015 -0700

----------------------------------------------------------------------
 3rdparty/libprocess/3rdparty/CMakeLists.txt      | 12 ++++++++++++
 3rdparty/libprocess/cmake/ProcessConfigure.cmake |  1 +
 2 files changed, 13 insertions(+)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/mesos/blob/868e7878/3rdparty/libprocess/3rdparty/CMakeLists.txt
----------------------------------------------------------------------
diff --git a/3rdparty/libprocess/3rdparty/CMakeLists.txt b/3rdparty/libprocess/3rdparty/CMakeLists.txt
index 0963222..d77f357 100644
--- a/3rdparty/libprocess/3rdparty/CMakeLists.txt
+++ b/3rdparty/libprocess/3rdparty/CMakeLists.txt
@@ -64,6 +64,7 @@ if (WIN32)
   # [1] https://github.com/google/glog/pull/43
   set(GLOG_URL     https://github.com/hausdorff/glog/tarball/glog-${GLOG_VERSION}-msvc1900)
   set(CURL_URL     ${UPSTREAM_URL}/curl-static-${CURL_VERSION}.tar.gz)
+  set(LIBAPR_URL   ${UPSTREAM_URL}/libapr-${LIBAPR_VERSION}.tar.gz)
 endif (WIN32)
 
 # Define build/patch/configure commands for third-party libs.
@@ -120,6 +121,8 @@ elseif (WIN32)
   set(RY_INSTALL_CMD ${CMAKE_NOOP})
 
   set(LIBEVENT_INSTALL_CMD ${CMAKE_NOOP})
+
+  set(LIBAPR_INSTALL_CMD ${CMAKE_NOOP})
 endif (NOT WIN32)
 
 # Third-party libraries. Tell the build system how to pull in and build third-
@@ -183,6 +186,15 @@ elseif (ENABLE_LIBEVENT)
     )
 endif (NOT ENABLE_LIBEVENT)
 
+if (WIN32)
+  ExternalProject_Add(
+    ${LIBAPR_TARGET}
+    PREFIX          ${LIBAPR_CMAKE_ROOT}
+    INSTALL_COMMAND ${LIBAPR_INSTALL_CMD}
+    URL             ${LIBAPR_URL}
+    )
+endif (WIN32)
+
 # WINDOWS THIRD-PARTY LIBRARIES. Windows has no package manager, so we download
 # them here.
 ###############################################################################

http://git-wip-us.apache.org/repos/asf/mesos/blob/868e7878/3rdparty/libprocess/cmake/ProcessConfigure.cmake
----------------------------------------------------------------------
diff --git a/3rdparty/libprocess/cmake/ProcessConfigure.cmake b/3rdparty/libprocess/cmake/ProcessConfigure.cmake
index 1467c97..a5dea3a 100755
--- a/3rdparty/libprocess/cmake/ProcessConfigure.cmake
+++ b/3rdparty/libprocess/cmake/ProcessConfigure.cmake
@@ -56,6 +56,7 @@ EXTERNAL("picojson"    ${PICOJSON_VERSION}    "${PROCESS_3RD_BIN}")
 EXTERNAL("http_parser" ${HTTP_PARSER_VERSION} "${PROCESS_3RD_BIN}")
 EXTERNAL("libev"       ${LIBEV_VERSION}       "${PROCESS_3RD_BIN}")
 EXTERNAL("libevent"    ${LIBEVENT_VERSION}    "${PROCESS_3RD_BIN}")
+EXTERNAL("libapr"      ${LIBAPR_VERSION}      "${PROCESS_3RD_BIN}")
 
 if (NOT WIN32)
   EXTERNAL("glog" ${GLOG_VERSION} "${PROCESS_3RD_BIN}")


Mime
View raw message