Click to See Complete Forum and Search --> : apache make error w/php4.x module SQL


Anon
09-01-2001, 08:20 AM
I'm running redhat 7.1. I have MySQL installed and running, I downloaded sources for PHP4 and Apache 1.x. After decompressing both within /usr/src These are the steps I took:

[/usr/src/apache]# ./configure --prefix=/usr/local/apache

[/usr/src/php4#] ./configure --with-mysql=/usr/local/mysql \
--with-apache=/usr/src/apache \
--with-zlib--enable-track-vars

make clean, make, make install

cd ../apache

./configure --prefix=/usr/local/apache \
--activate-module=src/modules/php4/libphp4.a

make, make install <-- and then I get the error:

/usr/local/mysql/lib/libmysqlclient.a(my_compress.0): In function `my_uncompress':
/usr/local/mysql/libmysqlclient.a(my_compress.o): In function `my_compress_alloc':
my_compress.o(.text+0x12a): undefined reference to `compress'
collect2: ld returned 1 exit status
make[2]: *** [target_static] Error 1
make[2]: *** Leaving directory `/usr/src/apache_1.3.20/src'
make[1]: *** [build-std] Error 2
make[1]: Leaving directory `/usr/src/apache_1.3.20/src'
make: *** [build] Error 2

I am at my wits end!!!! please have me with any advise you have.

It would be greatly appreciated!

comidio
09-01-2001, 07:08 PM
I had this problem and I solved but for the life of me can't remember exactly where the trouble was(this is why I am starting make set up dairies so I can go back and see how I solved a problem). So be assured that it can be solved.
First, is did you install MySQL from rpm or source. Mine is from source, and I think that had something to do with it. My current configure on php 4.0.6, is

--with-pfpro=shared,/pathto/verisign/payflowpro/linux
--enable-trackvars
--with-apache=path/to/apache_1.3.19
--with-java=/path/to/j2sdk1.3.1
--with-zlib
--with-mysql=/usr/local/mysql

and is very similar to yours. I think it has something to do with MySQL from rpm or binary. I honestly can't remember exactly what. Also as a last ditch leave off the mysql switch in the configure. You will still be able to access mysql and this will get you up and running.

CI

Anon
09-02-2001, 01:58 AM
Thanks for the input, I found what the problem was! (at least in my scenario):

Apache called "libphp4.a" in the make source instead of "libphp4.module". I edited the errors from "Makefile" and "Makefile.tmpl" and it compiled without any problem.

Anyone experiencing similar issues with PHP4/MySQL and Apache should read the tutorial at:

http://209.125.21.145/~tim/mysql.html