capi package (#7237)

cross_channel_norm
Yancey 7 years ago committed by GitHub
parent 673dc26cd4
commit 643ff03fbc
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

@ -193,6 +193,25 @@ EOF
EOF
}
function gen_capi_package() {
if [[ ${WITH_C_API} == "ON" ]]; then
install_prefix="/paddle/build/capi_output"
rm -rf $install_prefix
make DESTDIR="$install_prefix" install
if [[ ${WITH_MKL:-OFF} == "ON" ]]; then
find ./third_party/install -name 'libmklml_gnu.so' -exec cp {} $install_prefix/usr/local/lib \;
find ./third_party/install -name 'libmklml_intel.so' -exec cp {} $install_prefix/usr/local/lib \;
cp -P ./third_party/install/mkldnn/lib/* $install_prefix/usr/local/lib/
fi
find ./third_party/install -name 'libiomp5.so' -exec cp {} $install_prefix/usr/local/lib \;
cd $install_prefix/usr/local
ls | egrep -v "^Found.*item$" | xargs tar /paddle/build/paddle.tgz
fi
}
set -xe
cmake_gen ${PYTHON_ABI:-""}
@ -200,6 +219,11 @@ run_build
run_test
gen_docs
gen_dockerfile
printf "If you need to install PaddlePaddle in develop docker image,"
printf "please make install or pip install build/python/dist/*.whl.\n"
gen_capi_package
if [[ ${WITH_C_API:-OFF} == "ON" ]]; then
printf "PaddlePaddle C-API libraries was generated on build/paddle.tgz\n"
else
printf "If you need to install PaddlePaddle in develop docker image,"
printf "please make install or pip install build/python/dist/*.whl.\n"
fi

Loading…
Cancel
Save