-
-
Notifications
You must be signed in to change notification settings - Fork 13k
Description
Please note we will close your issue without comment if you delete, do not read or do not fill out the issue checklist below and provide ALL the requested information. If you repeatedly fail to use the issue template, we will block you from ever submitting issues to Homebrew again.
- are reporting a bug others will be able to reproduce and not asking a question or requesting software. If you're not sure or want to ask a question do so on our Discourse: https://discourse.brew.sh. To get software added or changed in Homebrew please file a Pull Request
- have a problem with
brew install
(orupgrade
,reinstall
) a single, Homebrew/homebrew-core formula (not cask) on macOS? If it's a generalbrew
problem please file this issue at Homebrew/brew: https://github.com/Homebrew/brew/issues/new/choose. If it's a Linux problem please file this issue at https://github.com/Homebrew/linuxbrew-core/issues/new/choose. If it's abrew cask
problem please file this issue at https://github.com/Homebrew/homebrew-cask/issues/new/choose. If it's a tap (e.g. Homebrew/homebrew-php) problem please file this issue at the tap. - ran
brew update
and can still reproduce the problem? - ran
brew doctor
, fixed all issues and can still reproduce the problem? - ran
brew gist-logs <formula>
(where<formula>
is the name of the formula that failed) and included the output link? - if
brew gist-logs
didn't work: ranbrew config
andbrew doctor
and included their output with your issue?
What you were trying to do
Install a PHP extension using Pecl (as these are no longer maintained as Homebrew formulas).
What happened
It seems by default, Homebrew installs php in a way that Pecl is unable to succeed installing a package. I've confirmed this with [email protected]
and [email protected]
on macOS 10.14.4.
$ pecl install apcu
downloading apcu-5.1.17.tgz ...
Starting to download apcu-5.1.17.tgz (94,814 bytes)
.....................done: 94,814 bytes
39 source files, building
…
Configuring for:
PHP Api Version: 20170718
Zend Module Api No: 20170718
Zend Extension Api No: 320170718
…
----------------------------------------------------------------------
Libraries have been installed in:
/private/tmp/pear/temp/pear-build-krinkleAMdnae/apcu-5.1.17/modules
Build complete.
Don't forget to run 'make test'.
running: make INSTALL_ROOT="/private/tmp/pear/temp/pear-build-krinkleAMdnae/install-apcu-5.1.17" install
Installing shared extensions: /private/tmp/pear/temp/pear-build-krinkleAMdnae/install-apcu-5.1.17/usr/local/Cellar/[email protected]/7.2.19_1/pecl/20170718/
Installing header files: /private/tmp/pear/temp/pear-build-krinkleAMdnae/install-apcu-5.1.17/usr/local/Cellar/[email protected]/7.2.19_1/include/php/
running: find "/private/tmp/pear/temp/pear-build-krinkleAMdnae/install-apcu-5.1.17" | xargs ls -dils
7864060 0 drwxr-xr-x 3 krinkle wheel 96 Jun 18 18:56 /private/tmp/pear/temp/pear-build-krinkleAMdnae/install-apcu-5.1.17
7864541 0 drwxr-xr-x 3 krinkle wheel 96 Jun 18 18:56 /private/tmp/pear/temp/pear-build-krinkleAMdnae/install-apcu-5.1.17/usr
7864542 0 drwxr-xr-x 3 krinkle wheel 96 Jun 18 18:56 /private/tmp/pear/temp/pear-build-krinkleAMdnae/install-apcu-5.1.17/usr/local
7864543 0 drwxr-xr-x 3 krinkle wheel 96 Jun 18 18:56 /private/tmp/pear/temp/pear-build-krinkleAMdnae/install-apcu-5.1.17/usr/local/Cellar
7864544 0 drwxr-xr-x 3 krinkle wheel 96 Jun 18 18:56 /private/tmp/pear/temp/pear-build-krinkleAMdnae/install-apcu-5.1.17/usr/local/Cellar/[email protected]
7864545 0 drwxr-xr-x 4 krinkle wheel 128 Jun 18 18:56 /private/tmp/pear/temp/pear-build-krinkleAMdnae/install-apcu-5.1.17/usr/local/Cellar/[email protected]/7.2.19_1
7864580 0 drwxr-xr-x 3 krinkle wheel 96 Jun 18 18:56 /private/tmp/pear/temp/pear-build-krinkleAMdnae/install-apcu-5.1.17/usr/local/Cellar/[email protected]/7.2.19_1/include
7864581 0 drwxr-xr-x 3 krinkle wheel 96 Jun 18 18:56 /private/tmp/pear/temp/pear-build-krinkleAMdnae/install-apcu-5.1.17/usr/local/Cellar/[email protected]/7.2.19_1/include/php
7864582 0 drwxr-xr-x 3 krinkle wheel 96 Jun 18 18:56 /private/tmp/pear/temp/pear-build-krinkleAMdnae/install-apcu-5.1.17/usr/local/Cellar/[email protected]/7.2.19_1/include/php/ext
7864583 0 drwxr-xr-x 17 krinkle wheel 544 Jun 18 18:56 /private/tmp/pear/temp/pear-build-krinkleAMdnae/install-apcu-5.1.17/usr/local/Cellar/[email protected]/7.2.19_1/include/php/ext/apcu
7864585 8 -rw-r--r-- 1 krinkle wheel 6232 Jun 18 18:56 /private/tmp/pear/temp/pear-build-krinkleAMdnae/install-apcu-5.1.17/usr/local/Cellar/[email protected]/7.2.19_1/include/php/ext/apcu/apc.h
7864586 4 -rw-r--r-- 1 krinkle wheel 1273 Jun 18 18:56 /private/tmp/pear/temp/pear-build-krinkleAMdnae/install-apcu-5.1.17/usr/local/Cellar/[email protected]/7.2.19_1/include/php/ext/apcu/apc_api.h
7864587 4 -rw-r--r-- 1 krinkle wheel 2603 Jun 18 18:56 /private/tmp/pear/temp/pear-build-krinkleAMdnae/install-apcu-5.1.17/usr/local/Cellar/[email protected]/7.2.19_1/include/php/ext/apcu/apc_arginfo.h
7864588 4 -rw-r--r-- 1 krinkle wheel 1967 Jun 18 18:56 /private/tmp/pear/temp/pear-build-krinkleAMdnae/install-apcu-5.1.17/usr/local/Cellar/[email protected]/7.2.19_1/include/php/ext/apcu/apc_cache.h
7864589 12 -rw-r--r-- 1 krinkle wheel 12129 Jun 18 18:56 /private/tmp/pear/temp/pear-build-krinkleAMdnae/install-apcu-5.1.17/usr/local/Cellar/[email protected]/7.2.19_1/include/php/ext/apcu/apc_cache_api.h
7864590 4 -rw-r--r-- 1 krinkle wheel 3635 Jun 18 18:56 /private/tmp/pear/temp/pear-build-krinkleAMdnae/install-apcu-5.1.17/usr/local/Cellar/[email protected]/7.2.19_1/include/php/ext/apcu/apc_globals.h
7864591 4 -rw-r--r-- 1 krinkle wheel 4032 Jun 18 18:56 /private/tmp/pear/temp/pear-build-krinkleAMdnae/install-apcu-5.1.17/usr/local/Cellar/[email protected]/7.2.19_1/include/php/ext/apcu/apc_iterator.h
7864592 4 -rw-r--r-- 1 krinkle wheel 1299 Jun 18 18:56 /private/tmp/pear/temp/pear-build-krinkleAMdnae/install-apcu-5.1.17/usr/local/Cellar/[email protected]/7.2.19_1/include/php/ext/apcu/apc_lock.h
7864594 8 -rw-r--r-- 1 krinkle wheel 4463 Jun 18 18:56 /private/tmp/pear/temp/pear-build-krinkleAMdnae/install-apcu-5.1.17/usr/local/Cellar/[email protected]/7.2.19_1/include/php/ext/apcu/apc_lock_api.h
7864593 4 -rw-r--r-- 1 krinkle wheel 2303 Jun 18 18:56 /private/tmp/pear/temp/pear-build-krinkleAMdnae/install-apcu-5.1.17/usr/local/Cellar/[email protected]/7.2.19_1/include/php/ext/apcu/apc_mutex.h
7864597 4 -rw-r--r-- 1 krinkle wheel 3033 Jun 18 18:56 /private/tmp/pear/temp/pear-build-krinkleAMdnae/install-apcu-5.1.17/usr/local/Cellar/[email protected]/7.2.19_1/include/php/ext/apcu/apc_serializer.h
7864595 4 -rw-r--r-- 1 krinkle wheel 1792 Jun 18 18:56 /private/tmp/pear/temp/pear-build-krinkleAMdnae/install-apcu-5.1.17/usr/local/Cellar/[email protected]/7.2.19_1/include/php/ext/apcu/apc_sma.h
7864596 8 -rw-r--r-- 1 krinkle wheel 5609 Jun 18 18:56 /private/tmp/pear/temp/pear-build-krinkleAMdnae/install-apcu-5.1.17/usr/local/Cellar/[email protected]/7.2.19_1/include/php/ext/apcu/apc_sma_api.h
7864598 4 -rw-r--r-- 1 krinkle wheel 2277 Jun 18 18:56 /private/tmp/pear/temp/pear-build-krinkleAMdnae/install-apcu-5.1.17/usr/local/Cellar/[email protected]/7.2.19_1/include/php/ext/apcu/apc_stack.h
7864584 4 -rw-r--r-- 1 krinkle wheel 2712 Jun 18 18:56 /private/tmp/pear/temp/pear-build-krinkleAMdnae/install-apcu-5.1.17/usr/local/Cellar/[email protected]/7.2.19_1/include/php/ext/apcu/php_apc.h
7864546 0 drwxr-xr-x 3 krinkle wheel 96 Jun 18 18:56 /private/tmp/pear/temp/pear-build-krinkleAMdnae/install-apcu-5.1.17/usr/local/Cellar/[email protected]/7.2.19_1/pecl
7864547 0 drwxr-xr-x 3 krinkle wheel 96 Jun 18 18:56 /private/tmp/pear/temp/pear-build-krinkleAMdnae/install-apcu-5.1.17/usr/local/Cellar/[email protected]/7.2.19_1/pecl/20170718
7864549 88 -rwxr-xr-x 1 krinkle wheel 88096 Jun 18 18:56 /private/tmp/pear/temp/pear-build-krinkleAMdnae/install-apcu-5.1.17/usr/local/Cellar/[email protected]/7.2.19_1/pecl/20170718/apcu.so
Build process completed successfully
Installing '/usr/local/Cellar/[email protected]/7.2.19_1/include/php/ext/apcu/apc_sma.h'
Installing '/usr/local/Cellar/[email protected]/7.2.19_1/include/php/ext/apcu/apc_sma_api.h'
Installing '/usr/local/Cellar/[email protected]/7.2.19_1/include/php/ext/apcu/apc_mutex.h'
Installing '/usr/local/Cellar/[email protected]/7.2.19_1/include/php/ext/apcu/apc_stack.h'
Installing '/usr/local/Cellar/[email protected]/7.2.19_1/include/php/ext/apcu/apc_arginfo.h'
Installing '/usr/local/Cellar/[email protected]/7.2.19_1/include/php/ext/apcu/apc.h'
Installing '/usr/local/Cellar/[email protected]/7.2.19_1/include/php/ext/apcu/apc_globals.h'
Installing '/usr/local/Cellar/[email protected]/7.2.19_1/include/php/ext/apcu/apc_iterator.h'
Installing '/usr/local/Cellar/[email protected]/7.2.19_1/include/php/ext/apcu/apc_lock_api.h'
Installing '/usr/local/Cellar/[email protected]/7.2.19_1/include/php/ext/apcu/apc_api.h'
Installing '/usr/local/Cellar/[email protected]/7.2.19_1/include/php/ext/apcu/php_apc.h'
Installing '/usr/local/Cellar/[email protected]/7.2.19_1/include/php/ext/apcu/apc_cache_api.h'
Installing '/usr/local/Cellar/[email protected]/7.2.19_1/include/php/ext/apcu/apc_cache.h'
Installing '/usr/local/Cellar/[email protected]/7.2.19_1/include/php/ext/apcu/apc_serializer.h'
Installing '/usr/local/Cellar/[email protected]/7.2.19_1/include/php/ext/apcu/apc_lock.h'
Installing '/usr/local/Cellar/[email protected]/7.2.19_1/pecl/20170718/apcu.so'
Warning: mkdir(): File exists in System.php on line 294
PHP Warning: mkdir(): File exists in /usr/local/Cellar/[email protected]/7.2.19_1/share/[email protected]/pear/System.php on line 294
Warning: mkdir(): File exists in /usr/local/Cellar/[email protected]/7.2.19_1/share/[email protected]/pear/System.php on line 294
ERROR: failed to mkdir /usr/local/Cellar/[email protected]/7.2.19_1/pecl/20170718
$ echo $?
1
Looking at what it was trying to operate on:
$ l /usr/local/Cellar/[email protected]/7.2.19_1
total 124K
drwxr-xr-x 15 krinkle staff 480 Jun 18 18:48 ./
drwxr-xr-x 3 krinkle staff 96 Jun 18 18:48 ../
drwxr-xr-x 4 krinkle staff 128 May 29 08:14 .bottle/
drwxr-xr-x 3 krinkle staff 96 May 29 08:14 .brew/
-rw-r--r-- 1 krinkle staff 3.1K Jun 18 18:48 INSTALL_RECEIPT.json
-rw-r--r-- 1 krinkle staff 3.2K May 29 08:14 LICENSE
-rw-r--r-- 1 krinkle staff 107K May 29 08:14 NEWS
-rw-r--r-- 1 krinkle staff 1.6K May 29 08:14 README.md
drwxr-xr-x 12 krinkle staff 384 Jun 18 18:48 bin/
-rw-r--r-- 1 krinkle staff 636 Jun 18 18:48 '[email protected]'
drwxr-xr-x 3 krinkle staff 96 May 29 08:14 include/
drwxr-xr-x 4 krinkle staff 128 May 29 08:14 lib/
lrwxr-xr-x 1 krinkle staff 23 Jun 18 18:48 pecl -> /usr/local/lib/php/pecl
drwxr-xr-x 3 krinkle staff 96 May 29 08:14 sbin/
drwxr-xr-x 5 krinkle staff 160 May 29 08:14 share/
There is an unexpected symlink here which is broken (/usr/local/lib/php/pecl
doesn't exist).
$ which pecl
/usr/local/opt/[email protected]/bin/pecl
Workaround
Removing this unexpected symlink and re-running the pecl
command makes it work.