Re: can't install PHP - keep getting "Invalid directory" error regarding the path to Apache httpd.h




Jerry Stuckle wrote:
David Haynes wrote:
Jerry Stuckle wrote:

lawrence k wrote:

I've installed Apache 1.3.36 on my Redhat EL 3 machine. Now I'm trying
to install PHP 5.1.4. I can not get the ./configure command to work. I
keep getting this error:

configure: error: Invalid Apache directory - unable to find httpd.h
under /usr/local/apache/include

So then I run this command:

find / -name httpd.h

which should find every file on my machine with the name "httpd.h".
These are the results I get:

/usr/local/apache/include/httpd.h
/home/shelley/apache_1.3.36/src/include/httpd.h

So I've rerun the ./configure command, using this first:

--with-apache=/usr/local/apche/include

and since that didn't work:

--with-apache=/home/shelley/apache_1.3.36/src/include/httpd.h

but I get the "Invalid directory" error with both addresses.

What am I missing?


Check the installation documentation. It's looking the base directory
for Apache - not the Apache include directory or an include file.

You must also have the Apache development code installed on your
system. Sorry, I don't use RedHat so I don't know which RPM you need.



I don't think you need to use --with-apache.
I think you need to use --with-apxs2 instead.
At least that works on my Fedora Core 4 system.

-david-


David,

You're right - it's been a while since I compiled PHP - and I have a script to
do it now.

Except in his case it should be --with-apxs as he's using Apache 1.x.

Okay, I'm now ending my configure command with this line:

--with-apxs=/usr/local/apache

and I get this error:

"The output of /usr/local/apache follows
../configure: line 4219: /usr/local/apache: is a directory
configure: error: Aborting"

I also tried:

--with-apxs=/usr/local/apache/include/httpd.h

but I got a "Permission denied" error, which I don't take seriously
since I didn't get it before, and, anyway, I'm logged in as root

What should --with-apxs be pointing to, while I'm installing PHP 5.1.4
on Apache 1.3.36?

.