update ray cmake build process (#2853)
* use cmake to build ray project, no need to appply build.sh before cmake, fix some abuse of cmake, improve the build performance
* support boost external project, avoid using the system or build.sh boost
* keep compatible with build.sh, remove boost and arrow build from it.
* bugfix: parquet bison version control, plasma_java lib install problem
* bugfix: cmake, do not compile plasma java client if no need
* bugfix: component failures test timeout machenism has problem for plasma manager failed case
* bugfix: arrow use lib64 in centos, travis check-git-clang-format-output.sh does not support other branches except master
* revert some fix
* set arrow python executable, fix format error in component_failures_test.py
* make clean arrow python build directory
* update cmake code style, back to support cmake minimum version 3.4
2018-09-13 02:19:33 +08:00
|
|
|
# flatbuffers external project
|
|
|
|
# target:
|
|
|
|
# - flatbuffer_ep
|
|
|
|
# depends:
|
|
|
|
#
|
|
|
|
# defines:
|
|
|
|
# - FLATBUFFERS_HOME
|
|
|
|
# - FLATBUFFERS_INCLUDE_DIR
|
|
|
|
# - FLATBUFFERS_STATIC_LIB
|
|
|
|
# - FLATBUFFERS_COMPILER
|
|
|
|
# - FBS_DEPENDS, to keep compatible
|
|
|
|
|
2018-10-11 05:33:15 +08:00
|
|
|
if(DEFINED ENV{RAY_FLATBUFFERS_HOME} AND EXISTS $ENV{RAY_FLATBUFFERS_HOME})
|
|
|
|
set(FLATBUFFERS_HOME "$ENV{RAY_FLATBUFFERS_HOME}")
|
2018-09-23 21:52:33 +07:00
|
|
|
set(FLATBUFFERS_INCLUDE_DIR "${FLATBUFFERS_HOME}/include")
|
|
|
|
set(FLATBUFFERS_STATIC_LIB "${FLATBUFFERS_HOME}/lib${LIB_SUFFIX}/libflatbuffers.a")
|
|
|
|
set(FLATBUFFERS_COMPILER "${FLATBUFFERS_HOME}/bin/flatc")
|
|
|
|
|
|
|
|
add_custom_target(flatbuffers_ep)
|
|
|
|
else()
|
2018-12-23 14:56:34 -08:00
|
|
|
set(flatbuffers_VERSION "1.10.0")
|
2018-09-23 21:52:33 +07:00
|
|
|
set(flatbuffers_URL "https://github.com/google/flatbuffers/archive/v${flatbuffers_VERSION}.tar.gz")
|
2018-12-23 14:56:34 -08:00
|
|
|
set(flatbuffers_URL_MD5 "f7d19a3f021d93422b0bc287d7148cd2")
|
2018-09-23 21:52:33 +07:00
|
|
|
|
|
|
|
set(FLATBUFFERS_INSTALL_PREFIX "${CMAKE_CURRENT_BINARY_DIR}/external/flatbuffers-install")
|
update ray cmake build process (#2853)
* use cmake to build ray project, no need to appply build.sh before cmake, fix some abuse of cmake, improve the build performance
* support boost external project, avoid using the system or build.sh boost
* keep compatible with build.sh, remove boost and arrow build from it.
* bugfix: parquet bison version control, plasma_java lib install problem
* bugfix: cmake, do not compile plasma java client if no need
* bugfix: component failures test timeout machenism has problem for plasma manager failed case
* bugfix: arrow use lib64 in centos, travis check-git-clang-format-output.sh does not support other branches except master
* revert some fix
* set arrow python executable, fix format error in component_failures_test.py
* make clean arrow python build directory
* update cmake code style, back to support cmake minimum version 3.4
2018-09-13 02:19:33 +08:00
|
|
|
|
2018-09-23 21:52:33 +07:00
|
|
|
set(FLATBUFFERS_HOME "${FLATBUFFERS_INSTALL_PREFIX}")
|
|
|
|
set(FLATBUFFERS_INCLUDE_DIR "${FLATBUFFERS_INSTALL_PREFIX}/include")
|
|
|
|
set(FLATBUFFERS_STATIC_LIB "${FLATBUFFERS_INSTALL_PREFIX}/lib${LIB_SUFFIX}/libflatbuffers.a")
|
|
|
|
set(FLATBUFFERS_COMPILER "${FLATBUFFERS_INSTALL_PREFIX}/bin/flatc")
|
|
|
|
|
|
|
|
ExternalProject_Add(flatbuffers_ep
|
|
|
|
PREFIX external/flatbuffers
|
|
|
|
URL ${flatbuffers_URL}
|
|
|
|
URL_MD5 ${flatbuffers_URL_MD5}
|
|
|
|
CMAKE_ARGS
|
|
|
|
"-DCMAKE_CXX_FLAGS=-fPIC"
|
|
|
|
"-DCMAKE_INSTALL_PREFIX:PATH=${FLATBUFFERS_INSTALL_PREFIX}"
|
|
|
|
"-DFLATBUFFERS_BUILD_TESTS=OFF"
|
|
|
|
"-DCMAKE_BUILD_TYPE=RELEASE")
|
|
|
|
endif()
|
|
|
|
|
|
|
|
set(FBS_DEPENDS flatbuffers_ep)
|