php安装http扩展(sudo apt-get install)
2012-03-28 22:02
681 查看
转自:http://www.xwuxin.com/?p=1575点击打开链接
"
上面新需求准备采用kohana,kohana是很早之前从ci分出来的一个框架,轻量,没有像ci那样去兼容php4。kohana需要安装http扩展,在Ubuntu上折腾了下,遇到些问题记录在此:
在安装好pecl的前提下:
sudo apt-get install libcurl3-openssl-dev
sudo apt-get install libmagic-dev
如果你不安装libcurl3-openssl-dev,直接用pecl install pecl-http方式安装http扩展,它会给你报以下error:
checking for curl/curl.h… not found
configure: error: could not find curl/curl.h
ERROR: ‘/tmp/pear/temp/pecl_http/configure –with-http-curl-requests –with-http-zlib-compression=1 –with-http-magic-mime=no –with-http-shared-deps’ failed
configure: error: could not find magic.h
ERROR: `/tmp/pear/temp/pecl_http/configure –with-http-curl-requests –with-http-zlib-compression –with-http-magic-mime –with-http-shared-deps’ failed
接着安装http扩展:
sudo pecl install pecl_http
一路回车之后,完成安装。
打开php.ini,加上extension=http.so,重启你的web服务器即可。
"
注:安装pecl:
"
上面新需求准备采用kohana,kohana是很早之前从ci分出来的一个框架,轻量,没有像ci那样去兼容php4。kohana需要安装http扩展,在Ubuntu上折腾了下,遇到些问题记录在此:
在安装好pecl的前提下:
sudo apt-get install libcurl3-openssl-dev
sudo apt-get install libmagic-dev
如果你不安装libcurl3-openssl-dev,直接用pecl install pecl-http方式安装http扩展,它会给你报以下error:
checking for curl/curl.h… not found
configure: error: could not find curl/curl.h
ERROR: ‘/tmp/pear/temp/pecl_http/configure –with-http-curl-requests –with-http-zlib-compression=1 –with-http-magic-mime=no –with-http-shared-deps’ failed
configure: error: could not find magic.h
ERROR: `/tmp/pear/temp/pecl_http/configure –with-http-curl-requests –with-http-zlib-compression –with-http-magic-mime –with-http-shared-deps’ failed
接着安装http扩展:
sudo pecl install pecl_http
一路回车之后,完成安装。
打开php.ini,加上extension=http.so,重启你的web服务器即可。
"
注:安装pecl:
$ sudo apt-get install php5-dev php-pear
相关文章推荐
- sudo apt-get install安装的php bin目录在什么位置
- php扩展 oauth 安装(sudo apt-get)
- Ubuntu下使用 apt-get install 安装php扩展库mcrypt、curl、gd
- debian apt-get install的程序的安装目录如何确定 - [Ubuntu](转自:http://nicklj.blogbus.com/logs/33400628.html)
- ubuntu通过apt-get方式搭建lnmp环境以及php扩展安装
- 无法用sudo apt-get install sun-java6-jdk安装java
- Ubuntu中用sudo apt-get install安装某软件,结果出错:E: Unable to locate
- Ubuntu使用命令安装jdk失败的解决方案--sudo apt-get install sun-java6-jdk
- sudo apt-get install openssh-server 需要安装 sudo apt-get update 404错误解决办法 The authenticity of
- unbutu sudo apt-get install git 和 apt-get update时报 暂时不能解析域名“ archive.ubuntu.com” 安装失败
- Linux(Ubuntu)使用 sudo apt-get install 命令安装软件的目录在哪?(已解决)
- ubuntu通过apt-get方式搭建lnmp环境以及php扩展安装
- ubuntu 使用apt-get install 安装php5.6--php7
- ubuntu通过apt-get方式搭建lnmp环境以及php扩展安装
- Ubuntu使用命令安装jdk失败的解决方案--sudo apt-get install sun-java6-jdk
- 树莓派如何安装sudo apt-get install pillow
- 首先需要安装JDK 6 sudo apt-get install sun-java6-jdk 之后需要设置默认的java程序 sudo update-alternatives --config java 按照提示输入对应的选项,指定为JD
- Ubuntu使用命令安装jdk失败的解决方案--sudo apt-get install sun-java6-jdk
- sudo apt-get install subversion subversion-tools 安装客户端