You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@mesos.apache.org by ch...@apache.org on 2018/03/15 17:10:40 UTC
[2/2] mesos git commit: Built CSI spec proto files with CMake.
Built CSI spec proto files with CMake.
Review: https://reviews.apache.org/r/66015/
Project: http://git-wip-us.apache.org/repos/asf/mesos/repo
Commit: http://git-wip-us.apache.org/repos/asf/mesos/commit/1e3145f9
Tree: http://git-wip-us.apache.org/repos/asf/mesos/tree/1e3145f9
Diff: http://git-wip-us.apache.org/repos/asf/mesos/diff/1e3145f9
Branch: refs/heads/master
Commit: 1e3145f92391ee881a364245e672811f27fdb460
Parents: f0b33da
Author: Chun-Hung Hsiao <ch...@mesosphere.io>
Authored: Thu Mar 15 10:08:13 2018 -0700
Committer: Chun-Hung Hsiao <ch...@mesosphere.io>
Committed: Thu Mar 15 10:08:13 2018 -0700
----------------------------------------------------------------------
3rdparty/CMakeLists.txt | 21 +++++++++++++++++++++
3rdparty/cmake/Versions.cmake | 2 ++
src/CMakeLists.txt | 4 ++++
3 files changed, 27 insertions(+)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/mesos/blob/1e3145f9/3rdparty/CMakeLists.txt
----------------------------------------------------------------------
diff --git a/3rdparty/CMakeLists.txt b/3rdparty/CMakeLists.txt
index 61dc788..e0c1538 100644
--- a/3rdparty/CMakeLists.txt
+++ b/3rdparty/CMakeLists.txt
@@ -25,6 +25,7 @@ endif ()
# TODO(andschwa): Move each URL to the dependency itself.
set(BOOST_URL ${FETCH_URL}/boost-${BOOST_VERSION}.tar.gz)
set(CONCURRENTQUEUE_URL ${FETCH_URL}/concurrentqueue-${CONCURRENTQUEUE_VERSION}.tar.gz)
+set(CSI_URL ${FETCH_URL}/csi-${CSI_VERSION}.tar.gz)
set(ELFIO_URL ${FETCH_URL}/elfio-${ELFIO_VERSION}.tar.gz)
set(GLOG_URL ${FETCH_URL}/glog-${GLOG_VERSION}.tar.gz)
set(GOOGLETEST_URL ${FETCH_URL}/googletest-release-${GOOGLETEST_VERSION}.tar.gz)
@@ -254,6 +255,26 @@ else ()
endif ()
+# CSI: Container Storage Interface Specification.
+# https://github.com/container-storage-interface/spec
+#####################################################
+EXTERNAL(csi ${CSI_VERSION} ${CMAKE_CURRENT_BINARY_DIR})
+add_library(csi INTERFACE)
+add_dependencies(csi ${CSI_TARGET})
+target_include_directories(csi INTERFACE ${CSI_ROOT})
+
+# NOTE: We hard-code `csi.proto` as a byproduct since it exists in the tarball.
+ExternalProject_Add(
+ ${CSI_TARGET}
+ PREFIX ${CSI_CMAKE_ROOT}
+ BUILD_BYPRODUCTS ${CSI_ROOT}/csi.proto
+ CONFIGURE_COMMAND ${CMAKE_NOOP}
+ BUILD_COMMAND ${CMAKE_NOOP}
+ INSTALL_COMMAND ${CMAKE_NOOP}
+ URL ${CSI_URL}
+ URL_HASH ${CSI_HASH})
+
+
# ELFIO: library for reading and generating ELF files.
# http://elfio.sourceforge.net
######################################################
http://git-wip-us.apache.org/repos/asf/mesos/blob/1e3145f9/3rdparty/cmake/Versions.cmake
----------------------------------------------------------------------
diff --git a/3rdparty/cmake/Versions.cmake b/3rdparty/cmake/Versions.cmake
index 94b0d80..93f0322 100644
--- a/3rdparty/cmake/Versions.cmake
+++ b/3rdparty/cmake/Versions.cmake
@@ -2,6 +2,8 @@ set(BOOST_VERSION "1.65.0")
set(BOOST_HASH "SHA256=085A1696AE2E735AACD0A497d46AACD7EEC0476E0D39937162F642B92F406476")
set(CONCURRENTQUEUE_VERSION "7b69a8f")
set(CONCURRENTQUEUE_HASH "SHA256=B2741A1FB2172C2A829503A85D5EE7548BE7ED04236A3FD1EFD2B6088E065CB7")
+set(CSI_VERSION "0.1.0")
+set(CSI_HASH "SHA256=A19778BF1D3658C97855544D3C208BD8F2AD23A25D1B9487D5B9EF7874C50382")
set(CURL_VERSION "7.57.0")
set(CURL_HASH "SHA256=7CE35F207562674E71DBADA6891B37E3F043C1E7A82915CB9C2A17AD3A9D659B")
set(ELFIO_VERSION "3.2")
http://git-wip-us.apache.org/repos/asf/mesos/blob/1e3145f9/src/CMakeLists.txt
----------------------------------------------------------------------
diff --git a/src/CMakeLists.txt b/src/CMakeLists.txt
index 6fc45db..fb9e9d4 100644
--- a/src/CMakeLists.txt
+++ b/src/CMakeLists.txt
@@ -29,6 +29,10 @@ set(JAVA_PROTOBUF_SRC "")
# Build the protobuf structs.
#
# NOTE: The following `PROTOC_GENERATE` calls will list append to
+# `PUBLIC_PROTO_PATH`, `PUBLIC_PROTOBUF_INCLUDE_DIR` and `PUBLIC_PROTOBUF_SRC`.
+PROTOC_GENERATE(GRPC LIB csi TARGET csi)
+
+# NOTE: The following `PROTOC_GENERATE` calls will list append to
# `PUBLIC_PROTOBUF_SRC`.
PROTOC_GENERATE(TARGET mesos/agent/agent)
PROTOC_GENERATE(TARGET mesos/allocator/allocator)