未验证 提交 476bc134 编写于 作者: R risemeup1 提交者: GitHub

[CI]fix proxy problem (#56199)

* fix proxy problem

* fix leveldb bug

* fix proxy problem
上级 7f0bdf07
......@@ -82,3 +82,23 @@
path = third_party/gtest
url = https://github.com/google/googletest.git
ignore = dirty
[submodule "third_party/leveldb"]
path = third_party/leveldb
url = https://github.com/google/leveldb.git
ignore = dirty
[submodule "third_party/brpc"]
path = third_party/brpc
url = https://github.com/apache/brpc.git
ignore = dirty
[submodule "third_party/rocksdb"]
path = third_party/rocksdb
url = https://github.com/Thunderbrook/rocksdb
ignore = dirty
[submodule "third_party/absl"]
path = third_party/absl
url = https://github.com/abseil/abseil-cpp.git
ignore = dirty
[submodule "third_party/jitify"]
path = third_party/jitify
url = https://github.com/NVIDIA/jitify.git
ignore = dirty
......@@ -8,24 +8,6 @@ set(ABSL_CMAKE_CXX_FLAGS ${CMAKE_CXX_FLAGS})
set(ABSL_REPOSITORY "https://github.com/abseil/abseil-cpp.git")
set(ABSL_TAG "20210324.2")
if(NOT EXISTS ${ABSL_SOURCES_DIR})
message(
STATUS "Download absl source from ${ABSL_REPOSITORY} to ABSL_SOURCES_DIR")
execute_process(COMMAND ${GIT_EXECUTABLE} clone -b ${ABSL_TAG}
${ABSL_REPOSITORY} ${ABSL_SOURCES_DIR})
else()
# check git tag
execute_process(
COMMAND ${GIT_EXECUTABLE} -C ${ABSL_SOURCES_DIR} describe --tags
OUTPUT_VARIABLE CURRENT_TAG
OUTPUT_STRIP_TRAILING_WHITESPACE)
if(NOT ${CURRENT_TAG} STREQUAL ${ABSL_TAG})
message(STATUS "Checkout absl to ${ABSL_TAG}")
execute_process(COMMAND ${GIT_EXECUTABLE} -C ${ABSL_SOURCES_DIR} checkout
-q ${ABSL_TAG})
endif()
endif()
set(OPTIONAL_ARGS
"-DCMAKE_CXX_COMPILER=${CMAKE_CXX_COMPILER}"
"-DCMAKE_C_COMPILER=${CMAKE_C_COMPILER}"
......
......@@ -10,24 +10,6 @@ set(JITIFY_SOURCE_DIR ${PADDLE_SOURCE_DIR}/third_party/jitify)
set(JITIFY_URL https://github.com/NVIDIA/jitify.git)
set(JITIFY_TAG 57de649139c866eb83acacfe50c92ad7c6278776)
if(NOT EXISTS ${JITIFY_SOURCE_DIR})
execute_process(COMMAND ${GIT_EXECUTABLE} clone ${JITIFY_URL}
${JITIFY_SOURCE_DIR})
execute_process(COMMAND ${GIT_EXECUTABLE} -C ${JITIFY_SOURCE_DIR} checkout -q
${JITIFY_TAG})
else()
# check git tag
execute_process(
COMMAND ${GIT_EXECUTABLE} -C ${JITIFY_SOURCE_DIR} describe --tags
OUTPUT_VARIABLE CURRENT_TAG
OUTPUT_STRIP_TRAILING_WHITESPACE)
if(NOT ${CURRENT_TAG} STREQUAL ${JITIFY_TAG})
message(STATUS "Checkout JITIFY to ${JITIFY_TAG}")
execute_process(COMMAND ${GIT_EXECUTABLE} -C ${JITIFY_SOURCE_DIR} checkout
-q ${JITIFY_TAG})
endif()
endif()
ExternalProject_Add(
external_jitify
${EXTERNAL_PROJECT_LOG_ARGS}
......
......@@ -41,22 +41,6 @@ set(BRPC_SOURCE_DIR ${PADDLE_SOURCE_DIR}/third_party/brpc)
set(BRPC_URL https://github.com/apache/brpc.git)
set(BRPC_TAG 1.4.0)
if(NOT EXISTS ${BRPC_SOURCE_DIR})
execute_process(COMMAND ${GIT_EXECUTABLE} clone -b ${BRPC_TAG} ${BRPC_URL}
${BRPC_SOURCE_DIR})
else()
# check git tag
execute_process(
COMMAND ${GIT_EXECUTABLE} -C ${BRPC_SOURCE_DIR} describe --tags
OUTPUT_VARIABLE CURRENT_TAG
OUTPUT_STRIP_TRAILING_WHITESPACE)
if(NOT ${CURRENT_TAG} STREQUAL ${BRPC_TAG})
message(STATUS "Checkout brpc to ${BRPC_TAG}")
execute_process(COMMAND ${GIT_EXECUTABLE} -C ${BRPC_SOURCE_DIR} checkout -q
${BRPC_TAG})
endif()
endif()
# Reference https://stackoverflow.com/questions/45414507/pass-a-list-of-prefix-paths-to-externalproject-add-in-cmake-args
set(prefix_path
"${THIRD_PARTY_PATH}/install/gflags|${THIRD_PARTY_PATH}/install/leveldb|${THIRD_PARTY_PATH}/install/snappy|${THIRD_PARTY_PATH}/install/gtest|${THIRD_PARTY_PATH}/install/protobuf|${THIRD_PARTY_PATH}/install/zlib|${THIRD_PARTY_PATH}/install/glog"
......
......@@ -30,29 +30,6 @@ if(WITH_HETERPS AND WITH_PSLIB)
set(LEVELDN_CXXFLAGS "${LEVELDN_CXXFLAGS} -D_GLIBCXX_USE_CXX11_ABI=0")
endif()
file(GLOB LEVELDB_SOURCE_FILE_LIST ${LEVELDB_SOURCE_DIR})
list(LENGTH LEVELDB_SOURCE_FILE_LIST RES_LEN)
if(RES_LEN EQUAL 0)
execute_process(
COMMAND ${GIT_EXECUTABLE} clone -b ${LEVELDB_TAG}
https://github.com/google/leveldb.git ${LEVELDB_SOURCE_DIR})
else()
# check git tag
execute_process(
COMMAND ${GIT_EXECUTABLE} describe --abbrev=6 --always --tags
OUTPUT_VARIABLE VERSION
OUTPUT_STRIP_TRAILING_WHITESPACE ERROR_QUIET
WORKING_DIRECTORY ${LEVELDB_SOURCE_DIR})
if(NOT ${VERSION} STREQUAL ${LEVELDB_TAG})
file(REMOVE_RECURSE ${LEVELDB_PREFIX_DIR})
file(REMOVE_RECURSE ${LEVELDB_INSTALL_DIR})
message(
WARNING "leveldb version is not ${VERSION}, checkout to ${LEVELDB_TAG}")
execute_process(COMMAND ${GIT_EXECUTABLE} checkout ${LEVELDB_TAG}
WORKING_DIRECTORY ${LEVELDB_SOURCE_DIR})
endif()
endif()
ExternalProject_Add(
extern_leveldb
${EXTERNAL_PROJECT_LOG_ARGS}
......
......@@ -51,29 +51,6 @@ set(ROCKSDB_CMAKE_C_FLAGS
)
include_directories(${ROCKSDB_INCLUDE_DIR})
file(GLOB ROCKSDB_SOURCE_FILE_LIST ${ROCKSDB_SOURCE_DIR})
list(LENGTH ROCKSDB_SOURCE_FILE_LIST RES_LEN)
if(RES_LEN EQUAL 0)
execute_process(
COMMAND ${GIT_EXECUTABLE} clone -b ${ROCKSDB_TAG}
"https://github.com/Thunderbrook/rocksdb" ${ROCKSDB_SOURCE_DIR})
else()
# check git tag
execute_process(
COMMAND ${GIT_EXECUTABLE} describe --abbrev=6 --always --tags
OUTPUT_VARIABLE VERSION
OUTPUT_STRIP_TRAILING_WHITESPACE ERROR_QUIET
WORKING_DIRECTORY ${ROCKSDB_SOURCE_DIR})
if(NOT ${VERSION} STREQUAL ${ROCKSDB_TAG})
file(REMOVE_RECURSE ${ROCKSDB_PREFIX_DIR})
file(REMOVE_RECURSE ${ROCKSDB_INSTALL_DIR})
message(
WARNING "rocksdb version is not ${VERSION}, checkout to ${ROCKSDB_TAG}")
execute_process(COMMAND ${GIT_EXECUTABLE} checkout ${ROCKSDB_TAG}
WORKING_DIRECTORY ${ROCKSDB_SOURCE_DIR})
endif()
endif()
set(CMAKE_CXX_LINK_EXECUTABLE
"${CMAKE_CXX_LINK_EXECUTABLE} -pthread -Wl,--no-as-needed -ldl -lrt -lz")
if(WITH_ARM)
......
Subproject commit 278e0a071885a22dcd2fd1b5576cc44757299343
Subproject commit cf2a22000584f30309e49e01e634128b193abb3e
Subproject commit 57de649139c866eb83acacfe50c92ad7c6278776
Subproject commit 803d69203a62faf50f1b77897310a3a1fcae712b
Subproject commit 9e18bf0e273b081de54ef1227e6f1db9e02a472a
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册