[英]Unable to install php solr extension
Using pecl install -n solr
gives No releases available for package "pecl.php.net/solr" install failed
使用
pecl install -n solr
No releases available for package "pecl.php.net/solr" install failed
了No releases available for package "pecl.php.net/solr" install failed
Also tried pear install pecl/solr
which gives the same output : No releases available for package "pecl.php.net/solr" install failed
还尝试了
pear install pecl/solr
,它提供了相同的输出: No releases available for package "pecl.php.net/solr" install failed
I'm using a Mac and php56. 我正在使用Mac和php56。
Output of pecl -V
PEAR Version: 1.9.4 PHP Version: 5.6.25 Zend Engine Version: 2.6.0 Darwin Kernel Version 15.4.0: Fri Feb 26 22:08:05 PST 2016; root:xnu-3248.40.184~3/RELEASE_X86_64 x86_64
输出
pecl -V
PEAR Version: 1.9.4 PHP Version: 5.6.25 Zend Engine Version: 2.6.0 Darwin Kernel Version 15.4.0: Fri Feb 26 22:08:05 PST 2016; root:xnu-3248.40.184~3/RELEASE_X86_64 x86_64
PEAR Version: 1.9.4 PHP Version: 5.6.25 Zend Engine Version: 2.6.0 Darwin Kernel Version 15.4.0: Fri Feb 26 22:08:05 PST 2016; root:xnu-3248.40.184~3/RELEASE_X86_64 x86_64
Another important piece of information is that, pear
and pecl
were not available in my system, so I installed them using 另一个重要的信息是,我的系统中没有
pear
和pecl
,所以我使用它们安装它们
sudo php /usr/lib/php/install-pear-nozlib.phar -d /usr/local/lib/php -b /usr/local/bin
Update 更新
Tried sudo pecl install -n solr
and now it seems to go one step further 试过
sudo pecl install -n solr
,现在它似乎更进了一步
Cannot find autoconf. Please check your autoconf installation and the $PHP_AUTOCONF environment variable. Then, rerun this script. ERROR: phpize failed
Luckily stumbled upon 幸运的是偶然发现了
PEAR package install fails PEAR包安装失败
which led to execute pear list-upgrades
which showed some kind of permission issue with cache directory, manually created the directory using sudo
at the specified location ( /private/tmp/pear/cache
) 导致执行
pear list-upgrades
,显示缓存目录的某种权限问题,在指定位置使用sudo
手动创建目录( /private/tmp/pear/cache
)
And then used sudo to install the solr extension as sudo pecl install -n solr
which threw the following error : 然后使用sudo将solr扩展名安装为
sudo pecl install -n solr
,它引发了以下错误:
Cannot find autoconf. Please check your autoconf installation and the $PHP_AUTOCONF environment variable. Then, rerun this script.
brew install autoconf
followed by sudo pecl install solr
worked. brew install autoconf
后跟sudo pecl install solr
工作。
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.