Hi everyone,
So for starters I’m using PHP 7.2.14 on macOS. PHP 7.1.x is installed on the machine (/usr/bin
), and a development tool that we use where I work has installed 7.2 via Homebrew. I also have PHP 7.3 installed in /usr/local/bin
and use it sometimes when I’m tinkering with hobby things (it’s the version I keep up to the latest since our servers run 7.2). Everything is fine as far as getting PHP set up is concerned, but today I tried to install Xdebug with PECL and then manually, and got the same error each time when running phpize
:
/Library/Developer/CommandLineTools/usr/bin/m4:aclocal.m4:3290: cannot open `build/ax_gcc_func_attribute.m4': No such file or directory autom4te: /usr/bin/m4 failed with exit status: 1
So I tried running the phpize
that’s included with PHP 7.3 and it worked, however caused an unrelated error when I tried to use the xdebug.so
that it compiled.
I noticed that versions of PHP prior to 7.2 do not include ax_gcc_func_attribute.m4
, which is present in the directory that I assume Homebrew’s installation of PHP used when building the interpreter (/usr/local/opt/php@7.2/lib/php/build
). That’s the same directory that phpize
should be looking in for the file mentioned above, based on what I saw when I looked at the source code of phpize
. The only place where that file isn’t, is /usr/lib/php/build
which corresponds to PHP 7.1.
I’m not entirely sure I’m looking at this problem the right way, and I don’t think I have the knowledge necessary to really debug this issue. Does anyone know what might be causing this?
submitted by /u/parks_canada
[link] [comments]