在我的Mac上以自制软件安装php 71时出错 [英] Error installing php 71 with homebrew on my mac
问题描述
我已经和Vallet合作了一段时间.今天,我想将laravel 5.4更新为5.5.在这样做之前,我先运行composer global update
.导致Vallet停止工作.
I have been developing with Vallet for some time now. Today i wanted to update laravel 5.4 to 5.5. Before doing so i run composer global update
. Causing Vallet to stop working.
拳头我试图做到以下几点:
Fist i tried to do the following:
cd ~/.composer/
sudo chown -R $(whoami) vendor
来源: https://laracasts.com /discuss/channels/general-discussion/getting-valet-not-found-error
我没有解决问题.然后,我决定重新安装Vallet.在此,我做了以下事情:
I did not solve the issue. Then i decided to reinstall Vallet. Hereby i did the following:
我遵循了此规则: https://github.com/laravel/valet/issues/321
停止和卸载服务
sudo brew services stop php71 dnsmasq nginx
brew uninstall php71 dnsmasq nginx
删除相关的配置文件和代客主文件夹
Remove related config files and valet home folder
sudo rm -r /usr/local/etc/php /usr/local/etc/nginx /usr/local/etc/dnsmasq.conf
sudo rm -r ~/.valet /var/root/.valet
我尝试过的安装服务:
brew install php71
$ brew tap homebrew/php
$ brew install php71
brew install homebrew/php/php71
所有人都给出了以下错误:
All gave the following error:
MacBook-Pro:~ mblivier$ brew install homebrew/php/php71
==> Installing php71 from homebrew/php Error: The following formula: php71
cannot be installed as a binary package and must be built from source.
Install the Command Line Tools:xcode-select --install
我是新来的,不知道该如何解决.关于如何安装php以及进一步重新安装Vallet的任何建议?
I new in this and don't know how to solve this. Any suggestions how to install php and go further with reinstalling Vallet?
- homebrew已安装并正常运行
推荐答案
您需要xcode来构建php,因此请先运行:
You need xcode to build php, so first run:
xcode-select --install
要安装xcode,以后您可以brew install php71
to install xcode and later you can brew install php71
这篇关于在我的Mac上以自制软件安装php 71时出错的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!