代码拉取完成,页面将自动刷新
同步操作将从 libpdk/libpdk 强制同步,此操作会覆盖自 Fork 仓库以来所做的任何修改,且无法恢复!!!
确定后同步将在后台操作,完成时将刷新页面,请耐心等待。
#!/bin/bash
function _cleanup()
{
unset -f _usage _cleanup ; return 0
}
## Clear out nested functions on exit
trap _cleanup INT EXIT RETURN
###### some declarations ######
forceBuild=no
function _usage() {
###### U S A G E : Help and ERROR ######
echo $@
echo "Usage:"
echo "./install [-f]"
}
[ $# = 0 ] && _usage " >>>>>>>> no options given "
##################################################################
####### "getopts" with: short options AND long options #######
####### AND short/long arguments #######
while getopts ':f-' OPTION ; do
case "$OPTION" in
f ) forceBuild=yes ;;
- ) [ $OPTIND -ge 1 ] && optind=$(expr $OPTIND - 1 ) || optind=$OPTIND
eval OPTION="\$$optind"
OPTARG=$(echo $OPTION | cut -d'=' -f2)
OPTION=$(echo $OPTION | cut -d'=' -f1)
case $OPTION in
--force ) forceBuild=yes ;;
* ) _usage " Long: >>>>>>>> invalid options (long) ";exit 1;;
esac
OPTIND=1
shift
;;
? ) _usage "Short: >>>>>>>> invalid options (short) ";exit 1;;
esac
done
echo -e "Welcome to use libpdk project"
if [ ! -d "build" ]
then
echo -e "create the build directory"
mkdir build
cd build
else
cd build
if [ "$forceBuild" == "yes" ]
then
echo -e "clean the build directory"
rm -Rf *
fi
fi
echo -e "init the submodules of libpdk project"
git submodule init
echo -e "build configure libpdk"
cmake ../
if [ $? ]
then
echo "something is wrong, maybe the build system can't find php-config"
echo "you can try ./install --php-config-path=path"
fi
此处可能存在不合适展示的内容,页面不予展示。您可通过相关编辑功能自查并修改。
如您确认内容无涉及 不当用语 / 纯广告导流 / 暴力 / 低俗色情 / 侵权 / 盗版 / 虚假 / 无价值内容或违法国家有关法律法规的内容,可点击提交进行申诉,我们将尽快为您处理。