簡體   English   中英

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

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

我一直在嘗試使用命令在MacOS High sierra中使用自制軟件安裝pcntl擴展

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

還嘗試了php54,55,56,70我收到錯誤

更新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.

為什么它沒有在我的Mac上找到公式我在我的Mac上有php 7.1.14

從brew成功安裝php@7.2后。 停止php7.1並啟動php7.2

brew services stop php@7.1
brew unlink php71

brew services start php@7.2
brew link php72

如果失敗,請執行以下操作

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

在2018年2月和3月, 當前支持的PHP版本 (撰寫本文時為5.6,7.0,7.1,7.2)的PHP公式被移至核心Homebrew tap,並於2018年4月PHP存檔已存檔。

要安裝當前的PHP版本(7.2),請使用:

$ brew install php

要安裝其他支持的版本之一,請使用:

$ brew install php@5.6

(替換5.67.07.1的其它版本)。

以這種方式安裝的所有公式都包含pcntl擴展,不需要任何其他內容。

暫無
暫無

聲明:本站的技術帖子網頁,遵循CC BY-SA 4.0協議,如果您需要轉載,請注明本站網址或者原文地址。任何問題請咨詢:yoyou2525@163.com.

 
粵ICP備18138465號  © 2020-2024 STACKOOM.COM