源码网商城,靠谱的源码在线交易网站 我的订单 购物车 帮助

源码网商城

linux安装php扩展脚本分享

  • 时间:2020-10-15 14:49 编辑: 来源: 阅读:
  • 扫一扫,手机访问
摘要:linux安装php扩展脚本分享
测试环境:ubuntu 12.04 php 5.3.x
[u]复制代码[/u] 代码如下:
#!/bin/bash #Program: # Accomplish to expand the specified function only one key #History: # 2013/11/15 pankai<530911044@qq.com> first release test ! -f ./ext_skel && echo "The shell script of 'ext_skel' doesn't exist in current directory.\n" && exit 0 [ ! -d "skeleton" ] && echo "The directory of 'skeleton' doesn't exist in current directory.\n" && exit 0 #include "./ext_skel" read -p "Please input the extension name: " ext_name #echo -e "hello $ext_name" #The blank space is necessary #Error: #  like: if[ ! -d "$ext_name" ]; then if [ ! -d "$ext_name" ]; then  ./ext_skel --extname=$ext_name fi file="./$ext_name/config.m4" copy="./$ext_name/config" if [ ! -f "./$ext_name/configs" ]; then  # Create a new file and clear it if it exists  :> "$copy"  cat "$file" | while read line  #for line in $( cat ./zend/config.m4 )  do   string=$( echo $line | grep 'PHP_ARG_ENABLE' )   if [ "$string" != ""  ]; then    echo $line | cut -c5- >> $copy    read line    echo $line | cut -c5- >> $copy    read line    echo $line | cut -c5- >> $copy    read line   fi   echo $line >> $copy  done  mv "$file" "./$ext_name/configs"  mv "$copy" "./$ext_name/config.m4" fi cd $ext_name phpize ./configure
  • 全部评论(0)
联系客服
客服电话:
400-000-3129
微信版

扫一扫进微信版
返回顶部