通过 pecl 安装 php 扩展 OAuth 时出错,请帮助我

通过 pecl 安装 php 扩展 OAuth 时出错,请帮助我

我正在尝试在我的 centos 6 linux 服务器中安装 php 扩展 OAuth。php.net 建议这非常简单。你只需运行

pecl install oauth

我尝试了这个,这是终端中的输出:


[root@www extensions]# pecl install oauth 
WARNING: channel "pecl.php.net" has updated its protocols, use "pecl channel-update 
pecl.php.net" to update
downloading oauth-1.2.2.tgz ...
Starting to download oauth-1.2.2.tgz (45,348 bytes)
.............done: 45,348 bytes
6 source files, building
running: phpize
Configuring for:
PHP Api Version:         20100412
Zend Module Api No:      20100525
Zend Extension Api No:   220100525
building in /var/tmp/pear-build-rootlyYnpP/oauth-1.2.2
running: /var/tmp/oauth/configure
checking for grep that handles long lines and -e... /bin/grep
checking for egrep... /bin/grep -E
checking for a sed that does not truncate output... /bin/sed
checking for cc... cc
checking for C compiler default output file name... a.out
checking whether the C compiler works... yes
checking whether we are cross compiling... no
checking for suffix of executables...
checking for suffix of object files... o
checking whether we are using the GNU C compiler... yes
checking whether cc accepts -g... yes
checking for cc option to accept ISO C89... none needed
checking how to run the C preprocessor... cc -E
checking for icc... no
checking for suncc... no
checking whether cc understands -c and -o together... yes
checking for system library directory... lib
checking if compiler supports -R... no
checking if compiler supports -Wl,-rpath,... yes
checking build system type... i686-pc-linux-gnu
checking host system type... i686-pc-linux-gnu
checking target system type... i686-pc-linux-gnu
configure: error: Cannot find php-config. Please use --with-php-config=PATH
ERROR: `/var/tmp/oauth/configure' failed

答案1

有一个错误:

configure: error: Cannot find php-config.

并且在同一行上,还有关于如何修复它的说明:

Please use --with-php-config=PATH

显然,PATH需要用您的实际路径替换php-config


如果您尚未php-config安装,则必须先安装它。

相关内容