You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@mesos.apache.org by mp...@apache.org on 2016/02/29 10:43:28 UTC

[2/2] mesos git commit: CMake:[1/2] Allow downloading third-party dependencies from mirror.

CMake:[1/2] Allow downloading third-party dependencies from mirror.

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


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

Branch: refs/heads/master
Commit: 6306b7d62dd5cbb34fa82636dfbb46cee46d0bf8
Parents: 947e7ba
Author: Alex Clemmer <cl...@gmail.com>
Authored: Mon Feb 29 04:23:05 2016 -0500
Committer: Michael Park <mp...@apache.org>
Committed: Mon Feb 29 04:43:18 2016 -0500

----------------------------------------------------------------------
 3rdparty/CMakeLists.txt | 11 ++++++++++-
 CMakeLists.txt          |  4 ++++
 2 files changed, 14 insertions(+), 1 deletion(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/mesos/blob/6306b7d6/3rdparty/CMakeLists.txt
----------------------------------------------------------------------
diff --git a/3rdparty/CMakeLists.txt b/3rdparty/CMakeLists.txt
index 3253da7..273cec7 100755
--- a/3rdparty/CMakeLists.txt
+++ b/3rdparty/CMakeLists.txt
@@ -22,7 +22,8 @@ add_subdirectory(libprocess)
 
 # Define sources of third-party dependencies.
 #############################################
-set(UPSTREAM_URL https://github.com/3rdparty/mesos-3rdparty/raw/master)
+set(UPSTREAM_URL ${3RDPARTY_DEPENDENCIES})
+
 set(REBUNDLED_DIR ${CMAKE_CURRENT_SOURCE_DIR})
 
 if (REBUNDLED)
@@ -31,6 +32,14 @@ else (REBUNDLED)
   set(ZOOKEEPER_URL ${UPSTREAM_URL}/zookeeper-${ZOOKEEPER_VERSION}.tar.gz)
 endif (REBUNDLED)
 
+if (WIN32)
+  # Similar to glog, on Windows, we use a different version of ZK. We'll
+  # eventually want to upgrade the Mesos project but for now this version of ZK
+  # does not come rebundled in the Mesos repository, so we need to get it from
+  # our canonical package mirror.
+  set(ZOOKEEPER_URL ${UPSTREAM_URL}/zookeeper-${ZOOKEEPER_VERSION}.tar.gz)
+endif (WIN32)
+
 # Define build/patch/configure commands for third-party libs.
 #############################################################
 if (NOT WIN32)

http://git-wip-us.apache.org/repos/asf/mesos/blob/6306b7d6/CMakeLists.txt
----------------------------------------------------------------------
diff --git a/CMakeLists.txt b/CMakeLists.txt
index 7f83dc8..fc0082f 100755
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -43,6 +43,10 @@ option(
   FALSE
   )
 set(CMAKE_VERBOSE_MAKEFILE ${VERBOSE})
+set(
+  3RDPARTY_DEPENDENCIES "https://github.com/3rdparty/mesos-3rdparty/raw/master"
+  CACHE STRING "Pass in a URL or filesystem path that points at a mirror of the canonical third-party dependency repository (https://github.com/3rdparty/mesos-3rdparty); this will cause Mesos to build against the third-party tarballs we find in the mirror, instead of going to the Internet or building against the rebundled tarballs in the Mesos repository.\n\nThis is especially useful for Windows builds, because building on MSVC 1900 requires newer versions of ZK, glog, and libevent, than the ones rebundled in the Mesos repository, and so in that case we normally would have to go to the Internet to get them. Using this flag, however, means we can avoid this.\nNOTE: If you use this in conjunction with the `REBUNDLED` flag, then we will only go to this repository when we would go to the Internet normally; on most Unix builds, this will mean you never go to the Internet, but on Windows, it means you will in the case of glog, ZK, and libevent. To build purely against the mirror, do not u
 se the `REBUNDLED` flag."
+  )
 
 if (REBUNDLED AND ENABLE_LIBEVENT)
   message(