PHP版本 | NTS配方 | Debug配方 | ZTS配方 | Debug ZTS配方 |
---|---|---|---|---|
PHP 5.6 | php@5.6 | php@5.6-debug | php@5.6-zts | php@5.6-debug-zts |
PHP 7.0 | php@7.0 | php@7.0-debug | php@7.0-zts | php@7.0-debug-zts |
PHP 7.1 | php@7.1 | php@7.1-debug | php@7.1-zts | php@7.1-debug-zts |
PHP 7.2 | php@7.2 | php@7.2-debug | php@7.2-zts | php@7.2-debug-zts |
PHP 7.3 | php@7.3 | php@7.3-debug | php@7.3-zts | php@7.3-debug-zts |
PHP 7.4 | php@7.4 | php@7.4-debug | php@7.4-zts | php@7.4-debug-zts |
PHP 8.0 | php@8.0 | php@8.0-debug | php@8.0-zts | php@8.0-debug-zts |
PHP 8.1 | php@8.1 | php@8.1-debug | php@8.1-zts | php@8.1-debug-zts |
PHP 8.2 | php@8.2 | php@8.2-debug | php@8.2-zts | php@8.2-debug-zts |
PHP 8.3 | php 或 php@8.3 | php-debug 或 php@8.3-debug | php-zts 或 php@8.3-zts | php-debug-zts 或 php@8.3-debug-zts |
PHP 8.4.0-dev | php@8.4 | php@8.4-debug | php@8.4-zts | php@8.4-debug-zts |
对于每个PHP版本,我们都提供了支持线程安全的配方(zts)、支持调试符号的配方(debug)以及同时支持两者的配方(debug-zts)。 带有调试符号的配方可用于构建或调试PHP扩展,不建议在生产环境中使用。 支持线程安全的配方可用于需要多线程支持的应用程序。
操作系统 | 架构 |
---|---|
Linux | x86_64 |
macOS Monterey | x86_64 , arm64 |
macOS Ventura | x86_64 , arm64 |
macOS Sonoma | x86_64 , arm64 |
xcode-select --install
# 使用APT sudo apt-get install -y curl git # 使用Yum sudo yum install -y curl git
/bin/bash -c "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install.sh)"
brew update
homebrew/php
tap中的包,请参考此指南进行清理。获取此tap中的配方:
brew tap shivammathur/php
查看PHP支持以了解可用的配方。
PHP 8.3
:brew install shivammathur/php/php@8.3
brew link --overwrite --force shivammathur/php/php@8.3
php -v
您可以将PHP版本升级到最新的补丁版本。
例如,升级PHP 8.3
:
brew upgrade shivammathur/php/php@8.3
例如,切换到PHP 8.3
:
brew link --overwrite --force shivammathur/php/php@8.3
警告:已链接: <Cellar 路径> 要重新链接: brew unlink <formula> && brew link <formula>
brew unlink php@8.3 brew link --overwrite --force shivammathur/php/php@8.3
如果你正在使用带有 php-fpm
的 Apache
或 Nginx
,在对 PHP 进行任何更改后重启你的网络服务器。
httpd
):brew services restart httpd
brew services restart nginx
确保在安装 PHP 之前运行了 brew update
。
运行 brew doctor
并修复它报告的警告。
确保 homebrew 有正确的权限。
sudo chown -R "$(id -un)":"$(id -gn)" $(brew --prefix)
例如,要重新安装 PHP 8.3
及其依赖项:
brew reinstall $(brew deps shivammathur/php/php@8.3) shivammathur/php/php@8.3
本项目中的代码根据 MIT 许可证授权。 更多信息请参阅许可证文件。
欢迎贡献! 在开始之前,请参阅贡献者指南。 如果你在使用这个 tap 时遇到任何问题,或想要建议功能/改进,请在这里创建一个讨论主题。
除了 GitHub Actions,我们还使用 MacStadium 作为我们的 CI 基础设施。
<a href="https://www.macstadium.com/opensource/members#gh-light-mode-only"> <img src="https://yellow-cdn.veclightyear.com/0a4dffa0/06b5af0c-7e54-4659-a5cb-cd51da0ed1c6.png" alt="Mac Stadium" width="200px"> </a> <a href="https://www.macstadium.com/opensource/members#gh-dark-mode-only"> <img src="https://yellow-cdn.veclightyear.com/0a4dffa0/653d64cc-4219-488c-8d8b-0ed6bf7c7727.png" alt="Mac Stadium" width="200px"> </a>本项目得到了许多其他用户和组织通过 GitHub 赞助商的慷慨支持。
<a href="https://github.com/sponsors/shivammathur"><img src="https://yellow-cdn.veclightyear.com/0a4dffa0/c6d2b2aa-7152-42d6-9d44-8aad93e4f231.svg?" alt="赞助 shivammathur"></a>
AI数字人视 频创作平台
Keevx 一款开箱即用的AI数字人视频创作平台,广泛适用于电商广告、企业培训与社媒宣传,让全球企业与个人创作者无需拍摄剪辑,就能快速生成多语言、高质量的专业视频。
一站式AI创作平台
提供 AI 驱动的图片、视频生成及数字人等功能,助力创意创作
AI办公助手,复杂任务高效处理
AI办公助手,复杂任务高效处理。办公效率低?扣子空间AI助手支持播客生成、PPT制作、网页开发及报告写作,覆盖科研、商业、舆情等领域的专家Agent 7x24小时响应,生活工作无缝切换,提升50%效率!
AI辅助编程,代码自动修复
Trae是一种自适应的集成开发环境(IDE),通过自动化和多元协作改变开发流程。利用Trae,团队能够更快速、精确地编写和部署代码,从而提高编程效率和项目交付速度。Trae具备上下文感知和代码自动完成功能,是提升开发效率的理想工具。