Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
PaddlePaddle
Paddle
提交
df1f2b5d
P
Paddle
项目概览
PaddlePaddle
/
Paddle
大约 1 年 前同步成功
通知
2299
Star
20931
Fork
5422
代码
文件
提交
分支
Tags
贡献者
分支图
Diff
Issue
1423
列表
看板
标记
里程碑
合并请求
543
Wiki
0
Wiki
分析
仓库
DevOps
项目成员
Pages
P
Paddle
项目概览
项目概览
详情
发布
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
Issue
1,423
Issue
1,423
列表
看板
标记
里程碑
合并请求
543
合并请求
543
Pages
分析
分析
仓库分析
DevOps
Wiki
0
Wiki
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
创建新Issue
提交
Issue看板
未验证
提交
df1f2b5d
编写于
6月 11, 2023
作者:
R
RedContritio
提交者:
GitHub
6月 11, 2023
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
【第三方库离线编译】add pslib, pslib_brpc cache (#54466)
* add pslib cache * fix bug
上级
a6b9120a
变更
2
显示空白变更内容
内联
并排
Showing
2 changed file
with
17 addition
and
6 deletion
+17
-6
cmake/external/pslib.cmake
cmake/external/pslib.cmake
+10
-3
cmake/external/pslib_brpc.cmake
cmake/external/pslib_brpc.cmake
+7
-3
未找到文件。
cmake/external/pslib.cmake
浏览文件 @
df1f2b5d
...
@@ -27,15 +27,18 @@ if((NOT DEFINED PSLIB_VER) OR (NOT DEFINED PSLIB_URL))
...
@@ -27,15 +27,18 @@ if((NOT DEFINED PSLIB_VER) OR (NOT DEFINED PSLIB_URL))
set
(
PSLIB_URL
set
(
PSLIB_URL
"https://pslib.bj.bcebos.com/pslib.tar.gz"
"https://pslib.bj.bcebos.com/pslib.tar.gz"
CACHE STRING
""
FORCE
)
CACHE STRING
""
FORCE
)
set
(
PSLIB_SUBDIR
"pslib"
)
else
()
else
()
set
(
PSLIB_URL
set
(
PSLIB_URL
"https://pslib.bj.bcebos.com/pslib_3631b2/pslib.tar.gz"
"https://pslib.bj.bcebos.com/pslib_3631b2/pslib.tar.gz"
CACHE STRING
""
FORCE
)
CACHE STRING
""
FORCE
)
set
(
PSLIB_SUBDIR
"pslib_3631b2"
)
endif
()
endif
()
endif
()
endif
()
message
(
STATUS
"PSLIB_NAME:
${
PSLIB_NAME
}
, PSLIB_URL:
${
PSLIB_URL
}
"
)
message
(
STATUS
"PSLIB_NAME:
${
PSLIB_NAME
}
, PSLIB_URL:
${
PSLIB_URL
}
"
)
set
(
PSLIB_PREFIX_DIR
"
${
THIRD_PARTY_PATH
}
/pslib"
)
set
(
PSLIB_PREFIX_DIR
"
${
THIRD_PARTY_PATH
}
/pslib"
)
set
(
PSLIB_
DOWNLOAD
_DIR
"
${
PSLIB_PREFIX_DIR
}
/src/
${
PSLIB_PROJECT
}
"
)
set
(
PSLIB_
SOURCE
_DIR
"
${
PSLIB_PREFIX_DIR
}
/src/
${
PSLIB_PROJECT
}
"
)
set
(
PSLIB_DST_DIR
"pslib"
)
set
(
PSLIB_DST_DIR
"pslib"
)
set
(
PSLIB_INSTALL_ROOT
"
${
THIRD_PARTY_PATH
}
/install"
)
set
(
PSLIB_INSTALL_ROOT
"
${
THIRD_PARTY_PATH
}
/install"
)
set
(
PSLIB_INSTALL_DIR
${
PSLIB_INSTALL_ROOT
}
/
${
PSLIB_DST_DIR
}
)
set
(
PSLIB_INSTALL_DIR
${
PSLIB_INSTALL_ROOT
}
/
${
PSLIB_DST_DIR
}
)
...
@@ -44,6 +47,7 @@ set(PSLIB_INC_DIR ${PSLIB_ROOT}/include)
...
@@ -44,6 +47,7 @@ set(PSLIB_INC_DIR ${PSLIB_ROOT}/include)
set
(
PSLIB_LIB_DIR
${
PSLIB_ROOT
}
/lib
)
set
(
PSLIB_LIB_DIR
${
PSLIB_ROOT
}
/lib
)
set
(
PSLIB_LIB
${
PSLIB_LIB_DIR
}
/libps.so
)
set
(
PSLIB_LIB
${
PSLIB_LIB_DIR
}
/libps.so
)
set
(
JVM_LIB
${
PSLIB_LIB_DIR
}
/libjvm.so
)
set
(
JVM_LIB
${
PSLIB_LIB_DIR
}
/libjvm.so
)
set
(
PSLIB_DOWNLOAD_DIR
"
${
PADDLE_SOURCE_DIR
}
/third_party/
${
PSLIB_SUBDIR
}
"
)
set
(
PSLIB_VERSION_PY
${
PSLIB_DOWNLOAD_DIR
}
/pslib/version.py
)
set
(
PSLIB_VERSION_PY
${
PSLIB_DOWNLOAD_DIR
}
/pslib/version.py
)
set
(
PSLIB_IOMP_LIB
${
PSLIB_LIB_DIR
}
/libiomp5.so
)
#todo what is this
set
(
PSLIB_IOMP_LIB
${
PSLIB_LIB_DIR
}
/libiomp5.so
)
#todo what is this
set
(
CMAKE_INSTALL_RPATH
"
${
CMAKE_INSTALL_RPATH
}
"
"
${
PSLIB_ROOT
}
/lib"
)
set
(
CMAKE_INSTALL_RPATH
"
${
CMAKE_INSTALL_RPATH
}
"
"
${
PSLIB_ROOT
}
/lib"
)
...
@@ -61,8 +65,11 @@ ExternalProject_Add(
...
@@ -61,8 +65,11 @@ ExternalProject_Add(
${
EXTERNAL_PROJECT_LOG_ARGS
}
${
EXTERNAL_PROJECT_LOG_ARGS
}
PREFIX
${
PSLIB_PREFIX_DIR
}
PREFIX
${
PSLIB_PREFIX_DIR
}
DOWNLOAD_DIR
${
PSLIB_DOWNLOAD_DIR
}
DOWNLOAD_DIR
${
PSLIB_DOWNLOAD_DIR
}
DOWNLOAD_COMMAND wget --no-check-certificate
${
PSLIB_URL
}
-c -q -O
DOWNLOAD_COMMAND
${
PSLIB_NAME
}
.tar.gz && tar zxvf
${
PSLIB_NAME
}
.tar.gz
COMMAND wget --no-check-certificate
${
PSLIB_URL
}
-c -q -O
${
PSLIB_NAME
}
.tar.gz
&& tar zxvf
${
PSLIB_NAME
}
.tar.gz -C
${
PSLIB_SOURCE_DIR
}
COMMAND
${
CMAKE_COMMAND
}
-E copy
"
${
PSLIB_DOWNLOAD_DIR
}
/CMakeLists.txt"
"
${
PSLIB_SOURCE_DIR
}
"
DOWNLOAD_NO_PROGRESS 1
DOWNLOAD_NO_PROGRESS 1
UPDATE_COMMAND
""
UPDATE_COMMAND
""
CMAKE_ARGS -DCMAKE_INSTALL_PREFIX=
${
PSLIB_INSTALL_ROOT
}
CMAKE_ARGS -DCMAKE_INSTALL_PREFIX=
${
PSLIB_INSTALL_ROOT
}
...
...
cmake/external/pslib_brpc.cmake
浏览文件 @
df1f2b5d
...
@@ -31,8 +31,7 @@ message(
...
@@ -31,8 +31,7 @@ message(
STATUS
STATUS
"PSLIB_BRPC_NAME:
${
PSLIB_BRPC_NAME
}
, PSLIB_BRPC_URL:
${
PSLIB_BRPC_URL
}
"
)
"PSLIB_BRPC_NAME:
${
PSLIB_BRPC_NAME
}
, PSLIB_BRPC_URL:
${
PSLIB_BRPC_URL
}
"
)
set
(
PSLIB_BRPC_PREFIX_DIR
"
${
THIRD_PARTY_PATH
}
/pslib_brpc"
)
set
(
PSLIB_BRPC_PREFIX_DIR
"
${
THIRD_PARTY_PATH
}
/pslib_brpc"
)
set
(
PSLIB_BRPC_DOWNLOAD_DIR
set
(
PSLIB_BRPC_SOURCE_DIR
"
${
PSLIB_PREFIX_DIR
}
/src/
${
PSLIB_BRPC_PROJECT
}
"
)
"
${
PSLIB_BRPC_PREFIX_DIR
}
/src/
${
PSLIB_BRPC_PROJECT
}
"
)
set
(
PSLIB_BRPC_DST_DIR
"pslib_brpc"
)
set
(
PSLIB_BRPC_DST_DIR
"pslib_brpc"
)
set
(
PSLIB_BRPC_INSTALL_ROOT
"
${
THIRD_PARTY_PATH
}
/install"
)
set
(
PSLIB_BRPC_INSTALL_ROOT
"
${
THIRD_PARTY_PATH
}
/install"
)
set
(
PSLIB_BRPC_INSTALL_DIR
${
PSLIB_BRPC_INSTALL_ROOT
}
/
${
PSLIB_BRPC_DST_DIR
}
)
set
(
PSLIB_BRPC_INSTALL_DIR
${
PSLIB_BRPC_INSTALL_ROOT
}
/
${
PSLIB_BRPC_DST_DIR
}
)
...
@@ -42,6 +41,7 @@ set(PSLIB_BRPC_LIB_DIR ${PSLIB_BRPC_ROOT}/lib)
...
@@ -42,6 +41,7 @@ set(PSLIB_BRPC_LIB_DIR ${PSLIB_BRPC_ROOT}/lib)
set
(
PSLIB_BRPC_LIB
${
PSLIB_BRPC_LIB_DIR
}
/libbrpc.a
)
set
(
PSLIB_BRPC_LIB
${
PSLIB_BRPC_LIB_DIR
}
/libbrpc.a
)
set
(
PSLIB_BRPC_IOMP_LIB
${
PSLIB_BRPC_LIB_DIR
}
/libiomp5.so
)
#todo what is this
set
(
PSLIB_BRPC_IOMP_LIB
${
PSLIB_BRPC_LIB_DIR
}
/libiomp5.so
)
#todo what is this
set
(
CMAKE_INSTALL_RPATH
"
${
CMAKE_INSTALL_RPATH
}
"
"
${
PSLIB_BRPC_ROOT
}
/lib"
)
set
(
CMAKE_INSTALL_RPATH
"
${
CMAKE_INSTALL_RPATH
}
"
"
${
PSLIB_BRPC_ROOT
}
/lib"
)
set
(
PSLIB_BRPC_DOWNLOAD_DIR
"
${
PADDLE_DOWLOAD_DIR
}
/third_party/pslib_brpc"
)
include_directories
(
${
PSLIB_BRPC_INC_DIR
}
)
include_directories
(
${
PSLIB_BRPC_INC_DIR
}
)
...
@@ -57,8 +57,12 @@ ExternalProject_Add(
...
@@ -57,8 +57,12 @@ ExternalProject_Add(
PREFIX
${
PSLIB_BRPC_PREFIX_DIR
}
PREFIX
${
PSLIB_BRPC_PREFIX_DIR
}
DOWNLOAD_DIR
${
PSLIB_BRPC_DOWNLOAD_DIR
}
DOWNLOAD_DIR
${
PSLIB_BRPC_DOWNLOAD_DIR
}
DOWNLOAD_COMMAND
DOWNLOAD_COMMAND
COMMAND
wget --no-check-certificate
${
PSLIB_BRPC_URL
}
-c -q -O
wget --no-check-certificate
${
PSLIB_BRPC_URL
}
-c -q -O
${
PSLIB_BRPC_NAME
}
.tar.gz && tar zxvf
${
PSLIB_BRPC_NAME
}
.tar.gz
${
PSLIB_BRPC_NAME
}
.tar.gz && tar zxvf
${
PSLIB_BRPC_NAME
}
.tar.gz -C
${
PSLIB_BRPC_SOURCE_DIR
}
COMMAND
${
CMAKE_COMMAND
}
-E copy
"
${
PSLIB_BRPC_DOWNLOAD_DIR
}
/CMakeLists.txt"
"
${
PSLIB_BRPC_SOURCE_DIR
}
"
DOWNLOAD_NO_PROGRESS 1
DOWNLOAD_NO_PROGRESS 1
UPDATE_COMMAND
""
UPDATE_COMMAND
""
CMAKE_ARGS -DCMAKE_INSTALL_PREFIX=
${
PSLIB_BRPC_INSTALL_ROOT
}
CMAKE_ARGS -DCMAKE_INSTALL_PREFIX=
${
PSLIB_BRPC_INSTALL_ROOT
}
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录