Ubuntu pecl安装pecl_http失败 [英] Ubuntu pecl install pecl_http fail

查看:527
本文介绍了Ubuntu pecl安装pecl_http失败的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在尝试安装此扩展程序,但在配置阶段失败.我在ubuntu 12.04上,我已经安装了以下软件包:

I'm trying to install this extension but it fails in the configuration phase. I'm on ubuntu 12.04 and I have just installed these packages:

  • libcurl3-openssl-dev
  • php-http
  • libpcre3-dev
  • libcurl3
  • php-pear
  • php5-dev

PHP版本:

PHP 5.3.10-1ubuntu3.14 with Suhosin-Patch (cli) (built: Sep  4 2014 07:08:49) 
Copyright (c) 1997-2012 The PHP Group
Zend Engine v2.3.0, Copyright (c) 1998-2012 Zend Technologies
    with Xdebug v2.1.0, Copyright (c) 2002-2010, by Derick Rethans

这是安装命令的日志:

sudo pecl install pecl_http
downloading pecl_http-2.1.1.tgz ...
Starting to download pecl_http-2.1.1.tgz (158,441 bytes)
.................................done: 158,441 bytes
64 source files, building
running: phpize
Configuring for:
PHP Api Version:         20090626
Zend Module Api No:      20090626
Zend Extension Api No:   220090626
Enable extended HTTP support [yes] : 
where to find zlib [/usr] : 
where to find libcurl [/usr] : 
where to find libevent [/usr] : 
building in /tmp/pear/temp/pear-build-rootqE2kgU/pecl_http-2.1.1
running: /tmp/pear/temp/pecl_http/configure --with-http --with-http-zlib-dir=/usr --with-http-libcurl-dir=/usr --with-http-libevent-dir=/home/gare88/Lib/Php/libevent-2.0.21-stable/
checking for grep that handles long lines and -e... /bin/grep

[... cut...]

checking for zlib.h... found in /usr
checking for zlib version >= 1.2.0.4... 1.2.3.4
checking for curl/curl.h... found in /usr
checking for curl-config... found: /usr/bin/curl-config
checking for curl version >= 7.18.2... 7.22.0
checking for SSL support in libcurl... yes
checking for openssl support in libcurl... no
checking for gnutls support in libcurl... no
checking for ares support in libcurl... no
checking for bundled SSL CA info... /etc/ssl/certs/ca-certificates.crt
checking for event2/event.h... not found
configure: WARNING: continuing without libevent support
checking for ext/raphf support... no
configure: error: Please install pecl/raphf and activate extension=raphf.so in your php.ini
ERROR: `/tmp/pear/temp/pecl_http/configure --with-http --with-http-zlib-dir=/usr --with-http-libcurl-dir=/usr --with-http-libevent-dir=/usr' failed

pecl/raphf 似乎有问题,所以我尝试了:

It seems that is a problem with pecl/raphf so I tried:

sudo pecl install raphf
pecl/raphf is already installed and is the same as the released version 1.0.4
install failed

位于/etc/php5/apache2/php.ini上的php.ini文件的末尾 我添加了一行:

At the end of php.ini file located on /etc/php5/apache2/php.ini I added the line:

extension=raphf.so
extension=propro.so
extension=http.so

还有什么我可以尝试的吗?

Is there anything else I can try?

推荐答案

您需要从包管理器中安装php-raphf.

You need to install php-raphf from your package manager.

对我来说,我使用以下方法安装了该模块.根据您的情况,您应该可以将yum切换为apt-get.

for me i installed the module using the following. In your case you should be able to switch out yum for apt-get.

sudo yum install php-raphf
sudo yum install php-propro
sudo pecl install pecl_http

您将需要将extension = http.so添加到您的php.ini文件中.但是看来您已经做到了.

The you will need to add extension = http.so to your php.ini file. But it looks like you have already done that.

pecl不会真正安装您要查找的.so文件.

pecl does not actually install the .so file that you are looking for.

这篇关于Ubuntu pecl安装pecl_http失败的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆