Fixing m4 on MAC OS 10.14.5

5.2k Views Asked by At

I'm having an issue with pecl which is erring out saying phpize had failed.

The problem ultimately seems to be with m4. Error is autom4te: need GNU m4 1.4 or later: /Applications/MAMP/Library/bin/m4

When I run "which m4" I get /Applications/MAMP/Library/bin/m4

However, any command I try to run with m4 like "m4 --version" I get the following:

Abort trap: 6

I can't find a good explanation of that error, but I'm guessing something is corrupted with m4, but I can't figure out how to fix this on a Mac. Do I just download a newer version and run configure, make and make install? Just a little nervous since I have somewhat limit Mac experience.

2

There are 2 best solutions below

0
Sergey Tsypanov On

I've fixed similar issue by executing brew reinstall m4.

1
John Langford On

In addition to a "brew (re)install m4", I had to temporarily remove "/Applications/MAMP/Library/bin" from my PATH. After that this worked for me.