低版本的Mac 安装PHP就是受罪
brew install shivammathur/php/[email protected] Warning: You are using macOS 11. We (and Apple) do not provide support for this old version. It is expected behaviour that some formulae will fail to build in this old version. It is expected behaviour that Homebrew will be buggy and slow. Do not create any issues about this on Homebrew's GitHub repositories. Do not create any issues even if you think this message is unrelated. Any opened issues will be immediately closed without response. Do not ask for help from Homebrew or its maintainers on social media. You may ask for help in Homebrew's discussions but are unlikely to receive a response. Try to figure out the problem yourself and submit a fix as a pull request. We will review it but may or may not accept it. Warning: shivammathur/php/[email protected] has been deprecated because it is a versioned formula! It was disabled on 2023-11-28. ==> Fetching dependencies for shivammathur/php/[email protected]: aom, libavif, gd, automake, gmp, krb5, libffi, libpq, libsodium, libzip, oniguruma and tidy-html5 ==> Fetching aom
去这个网站,把对应的版本下载下来:https://aomedia.googlesource.com/aom/+/refs/tags/v3.10.0
==> Fetching aom ==> Downloading https://raw.githubusercontent.com/Homebrew/homebrew-core/5ca04d553147f6cf1afdd6b553ab71e155889911/Formula/a/a Already downloaded: /Users/xxx/Library/Caches/Homebrew/downloads/ec676c47aebafccfc1afae4c98ba8659079203918b4bd3f1b7b6374ef2ac12bf--aom.rb ==> Cloning https://aomedia.googlesource.com/aom.git Cloning into '/Users/xxx/Library/Caches/Homebrew/aom--git'... fatal: unable to access 'https://aomedia.googlesource.com/aom.git/': Failed to connect to aomedia.googlesource.com port 443 after 76077 ms: Couldn't connect to server Error: [email protected]: Failed to download resource "aom" Failure while executing; `/usr/bin/env git clone --branch v3.10.0 --config advice.detachedHead=false --config core.fsmonitor=false https://aomedia.googlesource.com/aom.git /Users/xxx/Library/Caches/Homebrew/aom--git` exited with 128. Here's the output: Cloning into '/Users/xxx/Library/Caches/Homebrew/aom--git'... fatal: unable to access 'https://aomedia.googlesource.com/aom.git/': Failed to connect to aomedia.googlesource.com port 443 after 76077 ms: Couldn't connect to server
模拟 Cloning into '/Users/xxx/Library/Caches/Homebrew/aom--git'...
把源码文件拷贝到 /Users/xxx/Library/Caches/Homebrew/aom--3.10.0
切换到 build 目录下执行(很关键)
cmake -DCMAKE_INSTALL_PREFIX=/usr/local/Cellar/aom/3.10.0 ..
make
make install
cmake 不带路径 make install 就默认安装到 ```/usr/local/bin/```
最后看见就表示成功了, /usr/local/Cellar/aom/3.10.0 需要自己手动创建
Install the project... -- Install configuration: "Release" -- Installing: /usr/local/Cellar/aom/3.10.0/include/aom/aom.h -- Installing: /usr/local/Cellar/aom/3.10.0/include/aom/aom_codec.h -- Installing: /usr/local/Cellar/aom/3.10.0/include/aom/aom_frame_buffer.h -- Installing: /usr/local/Cellar/aom/3.10.0/include/aom/aom_image.h -- Installing: /usr/local/Cellar/aom/3.10.0/include/aom/aom_integer.h -- Installing: /usr/local/Cellar/aom/3.10.0/include/aom/aom_decoder.h -- Installing: /usr/local/Cellar/aom/3.10.0/include/aom/aomdx.h -- Installing: /usr/local/Cellar/aom/3.10.0/include/aom/aomcx.h -- Installing: /usr/local/Cellar/aom/3.10.0/include/aom/aom_encoder.h -- Installing: /usr/local/Cellar/aom/3.10.0/include/aom/aom_external_partition.h -- Installing: /usr/local/Cellar/aom/3.10.0/lib/pkgconfig/aom.pc -- Installing: /usr/local/Cellar/aom/3.10.0/lib/libaom.a -- Installing: /usr/local/Cellar/aom/3.10.0/bin/aomdec -- Installing: /usr/local/Cellar/aom/3.10.0/bin/aomenc
让 brew 识别 aom, 下面根据需要执行
brew link aom brew unlink aom && brew link aom brew link --overwrite aom brew list
标签:googlesource,Cellar,--,local,aom,3.10,connect,com,usr From: https://www.cnblogs.com/qk1314/p/18397129