Homebrew / brew

🍺 The missing package manager for macOS (or Linux)
https://brew.sh
BSD 2-Clause "Simplified" License
40.86k stars 9.59k forks source link

PHP PECL mkdir(): File exists in xxx #13930

Closed heyanlong closed 1 year ago

heyanlong commented 1 year ago

brew config output

HOMEBREW_VERSION: 3.6.3
ORIGIN: https://github.com/Homebrew/brew
HEAD: d5b6b068c15a8df60f0f5e34a4ca80dcf82c48e3
Last commit: 20 hours ago
Core tap ORIGIN: https://github.com/Homebrew/homebrew-core
Core tap HEAD: 45b6d2a25b6b9e780a39acbb1a94c2d2ed208363
Core tap last commit: 4 hours ago
Core tap branch: master
HOMEBREW_PREFIX: /usr/local
HOMEBREW_CASK_OPTS: []
HOMEBREW_MAKE_JOBS: 8
Homebrew Ruby: 2.6.8 => /System/Library/Frameworks/Ruby.framework/Versions/2.6/usr/bin/ruby
CPU: octa-core 64-bit kabylake
Clang: 14.0.0 build 1400
Git: 2.37.0 => /Library/Developer/CommandLineTools/usr/bin/git
Curl: 7.79.1 => /usr/bin/curl
macOS: 12.6-x86_64
CLT: 14.0.0.0.1.1661618636
Xcode: N/A

brew doctor output

Please note that these warnings are just used to help the Homebrew maintainers
with debugging if you file an issue. If everything you use Homebrew for is
working fine: please don't worry or file an issue; just ignore this. Thanks!

Warning: You have unlinked kegs in your Cellar.
Leaving kegs unlinked can lead to build-trouble and cause formulae that depend on
those kegs to fail to run properly once built. Run `brew link` on these:
  python@3.10

Warning: Homebrew's "sbin" was not found in your PATH but you have installed
formulae that put executables in /usr/local/sbin.
Consider setting your PATH for example like so:
  echo 'export PATH="/usr/local/sbin:$PATH"' >> ~/.zshrc

Verification

What were you trying to do (and why)?

I want to install PECL extension on macOS

What happened (include all command output)?

Output ERROR

Build process completed successfully
Installing '/usr/local/Cellar/php/8.1.10_1/pecl/20210902/skywalking_agent.so'

Warning: mkdir(): File exists in System.php on line 294
PHP Warning:  mkdir(): File exists in /usr/local/Cellar/php/8.1.10_1/share/php/pear/System.php on line 294

Warning: mkdir(): File exists in /usr/local/Cellar/php/8.1.10_1/share/php/pear/System.php on line 294
ERROR: failed to mkdir /usr/local/Cellar/php/8.1.10_1/pecl/20210902

What did you expect to happen?

Build process completed successfully
Installing '/usr/local/Cellar/php/8.1.10_1/pecl/20210902/skywalking_agent.so'
install ok: channel://pecl.php.net/skywalking_agent-0.1.0
Extension skywalking_agent enabled in php.ini

Step-by-step reproduction instructions (by running brew commands)

brew install php
pecl install skywalking_agent-0.1.0.tgz
heyanlong commented 1 year ago

I use the command to fix this error

pecl config-get ext_dir | pbcopy

mkdir -p {paste clipboard value}
github-actions[bot] commented 1 year ago

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs.