今天,我升级了Homebrew,这导致PHP版本(7.2-7.3)被删除。每当我尝试重新安装它们时,都会显示以下错误:
dyld: Library not loaded: /usr/local/opt/libpsl/lib/libpsl.5.dylib
Referenced from: /usr/local/opt/curl-openssl/bin/curl
Reason: image not found
Error: An exception occurred within a child process:
DownloadError: Failed to download resource "php"
Download failed: https://www.php.net/distributions/php-7.3.9.tar.xz
有什么建议吗?
答案 0 :(得分:1)
好的,我已经通过安装此库brew install libpsl
然后重新安装php brew reinstall php@7.2 --build-from-source
对于php@7.3也是如此
请注意,重新安装php会重置所有php配置
答案 1 :(得分:0)
这是将php
迁移到OpenSSH 1.1之后的一个错误。无需安装libpsl
。
该问题已由pr-44048解决。您应该卸载libpsl
,然后重新安装php
。
brew uninstall libpsl
brew reinstall php
答案 2 :(得分:0)
删除 Cellar 文件夹并再次安装 PHP 对我有用。
rm -rf /Users/rafaelgomes/.composer/*
rm -rf /usr/local/Cellar/*
brew doctor ; brew update ; brew upgrade
brew install php