Closed gusbemacbe closed 6 years ago
Encountering the same errors than @gusbemacbe with php@7.1.
Doing a simple brew upgrade
screwed all my PHP setup.
I would be interested in knowing how to properly migrate to this new tap and be able to install required dependencies.
All of the above mentioned core php extensions are now built statically (see output from php -m
or /usr/local/opt/php@7.1/bin/php -m
). You configuration file(s) (which were not touched by the migration) will need to be adjusted to take out any line that is referencing a shared extension (extension=
). The php formulae in Homebrew/core do not have any build options, so the bottle build should be fine (brew install php
).
The post_install
warning you are seeing is likely from a bad source build that reacted to old configuration files you have. Reviewing your homebrew logs (which you checked the box for, but didn't include) would show exactly what went wrong.
@kabel, I do not use PHP 7.1, I use PHP 7.2. Who uses it is @Romain.
Sorry. Assuming PHP 7.2 is the linked version php -m
, otherwise, /usr/local/opt/php/bin/php -m
. Also review your config at /usr/local/etc/php/7.2/php.ini
.
I have already modified /usr/local/etc/php/7.2/php.ini
to uncomment the extensions I needed and I also have reviewed php-fpm
and added a loadmodule and a fileswatch to httpd
as I have said in the first comment, but I have still the same errors of postinstall and of missed extensions/modules. I'll test php -m
on macOS when I will be home, because I am on Ubuntu now at college.
There is nothing to uncomment in the default config, the extensions you are looking for are just built in (no config needed). [EDIT] Those lines are in the default config mainly for Windows users.
The warning are coming from bad/old config from the previous tap. If you keep having issues, back up your /usr/local/etc/php/7.2/
directory, remove it, and do a reinstall with only brew install php
.
here is nothing to uncomment in the default config, the extensions you are looking for are just built in (no config needed). do a reinstall with only
brew install php
WIll it enable automatically all extensions I need?
Yes. That's what I mean by "built in".
OK, at home, firstly I will test php -m
, and if I have still the same erros, I will back up and remove the folder user/local/etc/php
.
@gusbemacbe You may need to install the extension through pecl
@kabel
I have just tested...
php -m
, all the extensions that I needed are present, but I had still the same errors.brew install php
and I was asked to reinstall. Then I runned brew reinstall php
, but I have still only one error of postinstall.brew postinstall php
and it gave an error: Error: Permission denied @ rb_sysopen - /usr/local/var/log/php-fpm.log
.php -v
and no errors. Good. But the error of postinstall is unsolved. @imajinyun, the formula pecl
has been removed from homebrew/core
together with the ancient formulae.
Here is the php-fpm.og
:
[03-Apr-2018 00:45:41] NOTICE: [pool www] 'user' directive is ignored when FPM is not running as root
[03-Apr-2018 00:45:41] NOTICE: [pool www] 'user' directive is ignored when FPM is not running as root
[03-Apr-2018 00:45:41] NOTICE: [pool www] 'group' directive is ignored when FPM is not running as root
[03-Apr-2018 00:45:41] NOTICE: [pool www] 'group' directive is ignored when FPM is not running as root
[03-Apr-2018 00:45:41] NOTICE: fpm is running, pid 2809
[03-Apr-2018 00:45:41] NOTICE: ready to handle connections
@imajinyun, ah, I ran brew list php
and it says it has already pecl
:
brew list php
/usr/local/Cellar/php/7.2.4/.bottle/etc/ (4 files)
/usr/local/Cellar/php/7.2.4/.bottle/var/log/php-fpm.log
/usr/local/Cellar/php/7.2.4/bin/pear
/usr/local/Cellar/php/7.2.4/bin/peardev
/usr/local/Cellar/php/7.2.4/bin/pecl
/usr/local/Cellar/php/7.2.4/bin/phar
/usr/local/Cellar/php/7.2.4/bin/phar.phar
/usr/local/Cellar/php/7.2.4/bin/php
/usr/local/Cellar/php/7.2.4/bin/php-cgi
/usr/local/Cellar/php/7.2.4/bin/php-config
/usr/local/Cellar/php/7.2.4/bin/phpdbg
/usr/local/Cellar/php/7.2.4/bin/phpize
/usr/local/Cellar/php/7.2.4/homebrew.mxcl.php.plist
/usr/local/Cellar/php/7.2.4/include/php/ (311 files)
/usr/local/Cellar/php/7.2.4/lib/httpd/modules/libphp7.so
/usr/local/Cellar/php/7.2.4/lib/php/ (14 files)
/usr/local/Cellar/php/7.2.4/sbin/php-fpm
/usr/local/Cellar/php/7.2.4/share/man/ (8 files)
/usr/local/Cellar/php/7.2.4/share/pear/ (158 files)
/usr/local/Cellar/php/7.2.4/share/php/fpm/status.html
But the error of postinstall is still unsolved.
Set ownership and permissions on those files such that your user can modify them and then re-run postinstall.
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.
brew install
(orupgrade
,reinstall
) a single, official formula (not cask)? If it's a generalbrew
problem please file this issue at Homebrew/brew: https://github.com/Homebrew/brew/issues/new. If it's abrew cask
problem please file this issue at https://github.com/caskroom/homebrew-cask/issues/new. If it's a tap (e.g. Homebrew/homebrew-php) problem please file this issue at the tap.brew update
and can still reproduce the problem?brew doctor
, fixed all issues and can still reproduce the problem?brew gist-logs <formula>
(where<formula>
is the name of the formula that failed) and included the output link?brew gist-logs
didn't work: ranbrew config
andbrew doctor
and included their output with your issue?To help us debug your issue please explain:
homebrew/core
and I had to upgrade, update, reinstall, uninstall, install, remove and install again, and there are still the some erros. I ranbrew doctor
and it didn't find errors of PHP, but runningphp -v
, I found the errors.index.php
. And it didn't find the modules ofcurl
,gettex
t,gmp
,intl
,mbstring
,openssl
,soap
andsockets
that were uncommented inphp.ini
because I nedded them.b. Running php -v:
brew install
commands)php72
andphp72-*
were removed and I wasn't aware thatphp72-*
were removed too, I changedphp72
tophp
:php.rb
:Unfortunately all these options were ignored and I have still the same errors
Formulae list:
Versions
OS version: macOS High Sierra 10.13.3 which php:
/usr/local/bin/php