Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
PaddlePaddle
Paddle-Lite
提交
e328cbc6
P
Paddle-Lite
项目概览
PaddlePaddle
/
Paddle-Lite
通知
331
Star
4
Fork
1
代码
文件
提交
分支
Tags
贡献者
分支图
Diff
Issue
271
列表
看板
标记
里程碑
合并请求
78
Wiki
0
Wiki
分析
仓库
DevOps
项目成员
Pages
P
Paddle-Lite
项目概览
项目概览
详情
发布
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
Issue
271
Issue
271
列表
看板
标记
里程碑
合并请求
78
合并请求
78
Pages
分析
分析
仓库分析
DevOps
Wiki
0
Wiki
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
创建新Issue
提交
Issue看板
未验证
提交
e328cbc6
编写于
2月 21, 2020
作者:
H
huzhiqiang
提交者:
GitHub
2月 21, 2020
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
[compile cherry-pick] add java lib and benchmark_bin into default publish result (#2958)
上级
d6782b88
变更
3
隐藏空白更改
内联
并排
Showing
3 changed file
with
6 addition
and
12 deletion
+6
-12
docs/installation/source_compile.md
docs/installation/source_compile.md
+1
-8
lite/CMakeLists.txt
lite/CMakeLists.txt
+4
-3
lite/tools/build.sh
lite/tools/build.sh
+1
-1
未找到文件。
docs/installation/source_compile.md
浏览文件 @
e328cbc6
...
@@ -260,7 +260,7 @@ git checkout <release-version-tag>
...
@@ -260,7 +260,7 @@ git checkout <release-version-tag>
| --arm_abi |必选,选择编译的arm版本,其中
`armv7hf`
为ARMLinux编译时选用|
`armv8`
、
`armv7`
、
`armv7hf`
(仅
`armlinux`
支持) |
| --arm_abi |必选,选择编译的arm版本,其中
`armv7hf`
为ARMLinux编译时选用|
`armv8`
、
`armv7`
、
`armv7hf`
(仅
`armlinux`
支持) |
| --arm_lang |arm_os=android时必选,选择编译器 |
`gcc`
、
`clang`
(
`clang`
当前暂不支持) |
| --arm_lang |arm_os=android时必选,选择编译器 |
`gcc`
、
`clang`
(
`clang`
当前暂不支持) |
| --android_stl |arm_os=android时必选,选择静态链接STL或动态链接STL |
`c++_static`
、
`c++_shared`
|
| --android_stl |arm_os=android时必选,选择静态链接STL或动态链接STL |
`c++_static`
、
`c++_shared`
|
| --build_java | 可选,是否编译java预测库(默认为O
FF
) |
`ON`
、
`OFF`
|
| --build_java | 可选,是否编译java预测库(默认为O
N
) |
`ON`
、
`OFF`
|
| --build_extra | 可选,是否编译全量预测库(默认为OFF)。详情可参考
[
预测库说明
](
./library.html
)
。 |
`ON`
、
`OFF`
|
| --build_extra | 可选,是否编译全量预测库(默认为OFF)。详情可参考
[
预测库说明
](
./library.html
)
。 |
`ON`
、
`OFF`
|
| target |必选,选择编译模式,
`tiny_publish`
为编译移动端部署库、
`full_publish`
为带依赖的移动端部署库、
`test`
为移动端单元测试、
`ios`
为编译ios端
`tiny_publish`
|
`tiny_publish`
、
`full_publish`
、
`test`
、
`ios`
|
| target |必选,选择编译模式,
`tiny_publish`
为编译移动端部署库、
`full_publish`
为带依赖的移动端部署库、
`test`
为移动端单元测试、
`ios`
为编译ios端
`tiny_publish`
|
`tiny_publish`
、
`full_publish`
、
`test`
、
`ios`
|
...
@@ -277,9 +277,7 @@ git checkout <release-version-tag>
...
@@ -277,9 +277,7 @@ git checkout <release-version-tag>
--arm_abi
=
armv8
\
--arm_abi
=
armv8
\
--build_extra
=
OFF
\
--build_extra
=
OFF
\
--arm_lang
=
gcc
\
--arm_lang
=
gcc
\
--build_java
=
ON
\
--android_stl
=
c++_static
\
--android_stl
=
c++_static
\
--build_extra
=
OFF
\
tiny_publish
tiny_publish
```
```
##### IOS
##### IOS
...
@@ -304,11 +302,9 @@ sudo xcode-select -s /Applications/Xcode.app/Contents/Developer
...
@@ -304,11 +302,9 @@ sudo xcode-select -s /Applications/Xcode.app/Contents/Developer
```
shell
```
shell
./lite/tools/build.sh
\
./lite/tools/build.sh
\
--build_extra
=
OFF
\
--build_extra
=
OFF
\
--build_java
=
ON
\
--arm_os
=
armlinux
\
--arm_os
=
armlinux
\
--arm_abi
=
armv7hf
\
--arm_abi
=
armv7hf
\
--arm_lang
=
gcc
\
--arm_lang
=
gcc
\
--build_extra
=
OFF
\
tiny_publish
tiny_publish
```
```
-
`--arm_abi`
: 树莓派3b使用armv7hf,RK3399使用armv8
-
`--arm_abi`
: 树莓派3b使用armv7hf,RK3399使用armv8
...
@@ -322,9 +318,7 @@ sudo xcode-select -s /Applications/Xcode.app/Contents/Developer
...
@@ -322,9 +318,7 @@ sudo xcode-select -s /Applications/Xcode.app/Contents/Developer
--arm_abi
=
armv8
\
--arm_abi
=
armv8
\
--build_extra
=
OFF
\
--build_extra
=
OFF
\
--arm_lang
=
gcc
\
--arm_lang
=
gcc
\
--build_java
=
ON
\
--android_stl
=
c++_static
\
--android_stl
=
c++_static
\
--build_extra
=
OFF
\
full_publish
full_publish
```
```
##### ARMLinux
##### ARMLinux
...
@@ -333,7 +327,6 @@ sudo xcode-select -s /Applications/Xcode.app/Contents/Developer
...
@@ -333,7 +327,6 @@ sudo xcode-select -s /Applications/Xcode.app/Contents/Developer
--arm_os
=
armlinux
\
--arm_os
=
armlinux
\
--arm_abi
=
armv7hf
\
--arm_abi
=
armv7hf
\
--arm_lang
=
gcc
\
--arm_lang
=
gcc
\
--build_java
=
ON
\
--build_extra
=
OFF
\
--build_extra
=
OFF
\
full_publish
full_publish
```
```
...
...
lite/CMakeLists.txt
浏览文件 @
e328cbc6
...
@@ -135,22 +135,23 @@ if (LITE_WITH_LIGHT_WEIGHT_FRAMEWORK AND LITE_WITH_ARM)
...
@@ -135,22 +135,23 @@ if (LITE_WITH_LIGHT_WEIGHT_FRAMEWORK AND LITE_WITH_ARM)
COMMAND cp
"
${
CMAKE_SOURCE_DIR
}
/lite/api/paddle_*.h"
"
${
INFER_LITE_PUBLISH_ROOT
}
/cxx/include"
COMMAND cp
"
${
CMAKE_SOURCE_DIR
}
/lite/api/paddle_*.h"
"
${
INFER_LITE_PUBLISH_ROOT
}
/cxx/include"
COMMAND cp
"
${
CMAKE_BINARY_DIR
}
/libpaddle_api_full_bundled.a"
"
${
INFER_LITE_PUBLISH_ROOT
}
/cxx/lib"
COMMAND cp
"
${
CMAKE_BINARY_DIR
}
/libpaddle_api_full_bundled.a"
"
${
INFER_LITE_PUBLISH_ROOT
}
/cxx/lib"
COMMAND cp
"
${
CMAKE_BINARY_DIR
}
/libpaddle_api_light_bundled.a"
"
${
INFER_LITE_PUBLISH_ROOT
}
/cxx/lib"
COMMAND cp
"
${
CMAKE_BINARY_DIR
}
/libpaddle_api_light_bundled.a"
"
${
INFER_LITE_PUBLISH_ROOT
}
/cxx/lib"
#COMMAND cp "${CMAKE_BINARY_DIR}/lite/api/model_optimize_tool" "${INFER_LITE_PUBLISH_ROOT}/bin"
COMMAND cp
"
${
CMAKE_BINARY_DIR
}
/lite/gen_code/paddle_code_generator"
"
${
INFER_LITE_PUBLISH_ROOT
}
/bin"
COMMAND cp
"
${
CMAKE_BINARY_DIR
}
/lite/gen_code/paddle_code_generator"
"
${
INFER_LITE_PUBLISH_ROOT
}
/bin"
COMMAND cp
"
${
CMAKE_BINARY_DIR
}
/lite/api/test_model_bin"
"
${
INFER_LITE_PUBLISH_ROOT
}
/bin"
COMMAND cp
"
${
CMAKE_BINARY_DIR
}
/lite/api/test_model_bin"
"
${
INFER_LITE_PUBLISH_ROOT
}
/bin"
COMMAND cp
"
${
CMAKE_SOURCE_DIR
}
/lite/utils/cv/paddle_*.h"
"
${
INFER_LITE_PUBLISH_ROOT
}
/cxx/include"
COMMAND cp
"
${
CMAKE_SOURCE_DIR
}
/lite/utils/cv/paddle_*.h"
"
${
INFER_LITE_PUBLISH_ROOT
}
/cxx/include"
)
)
if
(
NOT IOS
)
if
(
NOT IOS
)
#add_dependencies(publish_inference_cxx_lib model_optimize_tool)
add_dependencies
(
publish_inference_cxx_lib paddle_code_generator
)
add_dependencies
(
publish_inference_cxx_lib paddle_code_generator
)
add_dependencies
(
publish_inference_cxx_lib bundle_full_api
)
add_dependencies
(
publish_inference_cxx_lib bundle_full_api
)
add_dependencies
(
publish_inference_cxx_lib bundle_light_api
)
add_dependencies
(
publish_inference_cxx_lib bundle_light_api
)
add_dependencies
(
publish_inference_cxx_lib test_model_bin
)
add_dependencies
(
publish_inference_cxx_lib test_model_bin
)
add_dependencies
(
publish_inference_cxx_lib benchmark_bin
)
if
(
ARM_TARGET_OS STREQUAL
"android"
OR ARM_TARGET_OS STREQUAL
"armlinux"
)
if
(
ARM_TARGET_OS STREQUAL
"android"
OR ARM_TARGET_OS STREQUAL
"armlinux"
)
add_dependencies
(
publish_inference_cxx_lib paddle_full_api_shared
)
add_dependencies
(
publish_inference_cxx_lib paddle_full_api_shared
)
add_dependencies
(
publish_inference paddle_light_api_shared
)
add_dependencies
(
publish_inference paddle_light_api_shared
)
add_custom_command
(
TARGET publish_inference_cxx_lib
add_custom_command
(
TARGET publish_inference_cxx_lib
COMMAND cp
${
CMAKE_BINARY_DIR
}
/lite/api/*.so
${
INFER_LITE_PUBLISH_ROOT
}
/cxx/lib
)
COMMAND cp
${
CMAKE_BINARY_DIR
}
/lite/api/*.so
${
INFER_LITE_PUBLISH_ROOT
}
/cxx/lib
COMMAND cp
"
${
CMAKE_BINARY_DIR
}
/lite/api/benchmark_bin"
"
${
INFER_LITE_PUBLISH_ROOT
}
/bin"
)
endif
()
endif
()
add_dependencies
(
publish_inference publish_inference_cxx_lib
)
add_dependencies
(
publish_inference publish_inference_cxx_lib
)
if
(
NOT
"
${
CMAKE_BUILD_TYPE
}
"
STREQUAL
"Debug"
)
if
(
NOT
"
${
CMAKE_BUILD_TYPE
}
"
STREQUAL
"Debug"
)
...
...
lite/tools/build.sh
浏览文件 @
e328cbc6
...
@@ -14,7 +14,7 @@ readonly NUM_PROC=${LITE_BUILD_THREADS:-4}
...
@@ -14,7 +14,7 @@ readonly NUM_PROC=${LITE_BUILD_THREADS:-4}
# global variables
# global variables
BUILD_EXTRA
=
OFF
BUILD_EXTRA
=
OFF
BUILD_JAVA
=
O
FF
BUILD_JAVA
=
O
N
BUILD_PYTHON
=
OFF
BUILD_PYTHON
=
OFF
BUILD_DIR
=
$(
pwd
)
BUILD_DIR
=
$(
pwd
)
OPTMODEL_DIR
=
""
OPTMODEL_DIR
=
""
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录