我正在尝试在我的应用程序中包含Goutte的Laravel 5立面。但是我收到以下错误:
Problem 1
- namshi/jose 5.0.2 requires lib-openssl * -> the requested linked library openssl has the wrong version installed or is missing from your system, make sure to have the extension providing it.
- namshi/jose 5.0.2 requires lib-openssl * -> the requested linked library openssl has the wrong version installed or is missing from your system, make sure to have the extension providing it.
- namshi/jose 5.0.2 requires lib-openssl * -> the requested linked library openssl has the wrong version installed or is missing from your system, make sure to have the extension providing it.
- Installation request for namshi/jose (locked at 5.0.2) -> satisfiable by namshi/jose[5.0.2].
我已经在网上搜索过,它建议安装新版本的 PHP 并尝试使用它,但是我已经通过自制软件安装了 php56,但它仍然无法正常工作。当我运行时:
which php
它说路径是:
/usr/bin/php
然而,brew 安装了 php:
/usr/local/Cellar/php56/5.6.30_6/bin
我已使用以下行更新了我的.bash_profile:
export PATH=$PATH:/usr/local/Cellar/php56/5.6.30_6/bin
然而,即使在重新启动终端后,php 仍然返回/usr/bin/php。
您可以尝试通过以下方式为新的php版本创建符号链接:
sudo ln /usr/local/Cellar/php56/5.6.30_6/bin/php /usr/local/bin/php
然后运行作曲家命令
php composer require weidner/goutte
或
php composer.phar require weidner/goutte
希望这有帮助!