简体   繁体   English

无法在mac high sierra的homebrew上找到pcntl

[英]Unable to find pcntl on homebrew in mac high sierra

I have been trying to install pcntl extension using homebrew in MacOS High sierra using command 我一直在尝试使用命令在MacOS High sierra中使用自制软件安装pcntl扩展

brew install homebrew/php/php71-pcntl
brew install homebrew-php/php71-pcntl

Also tried with php54, 55, 56, 70 I m getting error 还尝试了php54,55,56,70我收到错误

Updating Homebrew... 更新Homebrew ...

Error: No available formula with the name "homebrew/php/php7-pcntl" 
==> Searching for a previously deleted formula (in the last month)...
Warning: homebrew/php is shallow clone. To get complete history run:
  git -C "$(brew --repo homebrew/php)" fetch --unshallow

Error: No previously deleted formula found.
==> Searching for similarly named formulae...
==> Searching local taps...
Error: No similarly named formulae found.

Why its not finding the formulae on my Mac I have php 7.1.14 on my mac 为什么它没有在我的Mac上找到公式我在我的Mac上有php 7.1.14

Once successfully installing php@7.2 from brew. 从brew成功安装php@7.2后。 Stop php7.1 and Start php7.2 停止php7.1并启动php7.2

brew services stop php@7.1
brew unlink php71

And

brew services start php@7.2
brew link php72

If it fails run the following 如果失败,请执行以下操作

  echo 'export PATH="/usr/local/opt/php@7.2/bin:$PATH"' >> ~/.zshrc
  echo 'export PATH="/usr/local/opt/php@7.2/sbin:$PATH"' >> ~/.zshrc

In February and March 2018 the PHP formulas for the currently supported PHP versions (5.6, 7.0, 7.1, 7.2 at the moment of this writing) were moved to the core Homebrew tap and in April 2018 the PHP tap has been archived. 在2018年2月和3月, 当前支持的PHP版本 (撰写本文时为5.6,7.0,7.1,7.2)的PHP公式被移至核心Homebrew tap,并于2018年4月PHP存档已存档。

To install the current PHP version (7.2) use: 要安装当前的PHP版本(7.2),请使用:

$ brew install php

To install one of the other supported versions use: 要安装其他支持的版本之一,请使用:

$ brew install php@5.6

(replace 5.6 with 7.0 or 7.1 for the other versions). (替换5.67.07.1的其它版本)。

All the formulas installed this way contain the pcntl extension, there is no need for anything else. 以这种方式安装的所有公式都包含pcntl扩展,不需要任何其他内容。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM