提交 2917aabd 编写于 作者: B barrierye

add app compile CI

上级 7847239f
......@@ -48,6 +48,29 @@ function rerun() {
exit 1
}
function build_app() {
local TYPE=$1
local DIRNAME=build-app-$TYPE
mkdir $DIRNAME # pwd: /Serving
cd $DIRNAME # pwd: /Serving/build-app-$TYPE
case $TYPE in
CPU|GPU)
cmake -DPYTHON_INCLUDE_DIR=$PYTHONROOT/include/python2.7/ \
-DPYTHON_LIBRARIES=$PYTHONROOT/lib/libpython2.7.so \
-DPYTHON_EXECUTABLE=$PYTHONROOT/bin/python \
-DAPP=ON ..
rerun "make -j2 >/dev/null" 3 # due to some network reasons, compilation may fail
pip install -U python/dist/paddle_serving_app* >/dev/null
;;
*)
echo "error type"
exit 1
;;
esac
echo "build app $TYPE part finished as expected."
cd .. # pwd: /Serving
}
function build_client() {
local TYPE=$1
local DIRNAME=build-client-$TYPE
......@@ -230,6 +253,7 @@ function main() {
init # pwd: /Serving
build_client $TYPE # pwd: /Serving
build_server $TYPE # pwd: /Serving
build_app $TYPE # pwd: /Serving
python_run_test $TYPE # pwd: /Serving
echo "serving $TYPE part finished as expected."
}
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册