The Fix for those Silly FreeBSD PHP Ports PHP_AUTOCONF Errors

August 27, 2007

If you’ve also been running into those PHP_AUTOCONF errors when trying to build php modules on FreeBSD, then you’ll be interested in this. The following two commands fixed the problem for me:

ln -s /usr/local/bin/autoheader-2.59 /usr/local/bin/autoheader259
ln -s /usr/local/bin/autoconf-2.59 /usr/local/bin/autoconf259

The error message I was getting is as follows:

Cannot find autoconf. Please check your autoconf installation and the $PHP_AUTOCONF environment variable is set correctly and then rerun this script

05-October-2007 Update

If you’re seeing this problem again with autoconf 2.61 and php 5.2.4 on FreeBSD 6.2, the new fix is to run these commands (assuming you are using a c shell):

setenv PHP_AUTOCONF autoconf-2.61
setenv PHP_AUTOHEADER autoheader-2.61

  • del.icio.us
  • Digg
  • Reddit
  • StumbleUpon
  • Mixx
  • Facebook
  • Live
  • Pownce
  • TwitThis
  • Technorati

{ 5 comments… read them below or add one }

Required 10.01.07 at 3:57 pm

Thank you! I just want to know, who pressed the wrong button for the port?!

x 10.16.07 at 9:29 am

Thanks. I needed this tip. Here is a small improvement:

setenv PHP_AUTOCONF autoconf
setenv PHP_AUTOHEADER autoheader

Regards,
OE

zeroreturn 11.05.07 at 7:57 am

I saw the same error while installing PHP, but then I understood that this is not a problem with freebsd ports.

What I did next was: “pkg_info | grep php”
There was php5-5.1.6_3 package already, so I did “pkg_delete php5-5.1.6_3″ and started “make install clean” in the ports folder. The port was installed smoothly.

George 09.03.08 at 10:08 am

Thanks X, I like your fix better actually.

simoncpu 09.16.08 at 1:44 am

Thanks!!! This really helped me a lot.

Leave a Comment

You can use these HTML tags and attributes: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>

By submitting a comment here you grant this site a perpetual license to reproduce your words and name/web site in attribution.

Older post: Three Reasons Why I’m Switching from Mac to Ubuntu

Newer post: Listen Empathically to Your Books