TCLUG Archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [TCLUG:9458] Copiliing PHP with MySQL support



Mike,

Does MySQL have a configure script? If so, you might want to run it. The
*.in files (like Makefile.in) lead me to believe that the *.h file are
generated during a configure script run. It might be worth a shot, but
good luck,

Troy

Mike Glaser wrote:
> For those of you that replied to my query earlier this week, thanks!
> I realized that I need to recompile the PHP source code to enable
> MySQL support. My problem is now I cannot compile the bloody thing
> after having spent close to three full days on it.
> Here is where I am at...
> I downloaded and unzipped the following three packages to /install
> apache_1.3.9.tar.gz
> php-3.0.12.tar.gz
> mysql-3.22.27.tar.gz
> Following the 'Quick Installation Instructions (Apache Module
> Version) that came with the PHP tarball, I have done the following:
> 1) from Apache directory: ./configure --prefix=/www
> 2) from php    directory: ./configure --with-mysql=../mysql_3.22.27
>                                       --with-apache=../apache_1.3.9
>                                       --enable-track-vars
> above gave me errors saying it could not find
> ../mysql_3.22.27/include/mysql_com.h and mysql_version.h
> Those two files were not in the include directory, but those files
> were there with a '.in' tacked on the end of them, so I made copies
> of each and removed the '.in' after the '.h'
> at this point I re-run the line in step 2 from above and the
> ./configure script seemed to run ok.
> 3) make
> This went on and on and finally went haywire with the following
> notice:
> In file included from functions/mysql.c:84:
> /install/php-3.0.12/../mysql-3.22.27/include/mysql.h:166:parse error
> functions/mysql.c:95:parse error
> functions/mysql.c:476:parse error
> functions/mysql.c:502:parse error
> functions/mysql.c:541:parse error
> functions/mysql.c:590:parse error
> functions/mysql.c:874:parse error
> functions/mysql.c:939:parse error
> When I went into vi and examined the line numbers above, each went
> something like:
> if MYSQL_VERSION_ID < 32200 .......
> in each case, the constant MYSQL_VERSION_ID  (that may not be EXACTLY
> what it was named) was in the line that could not be 'parsed'.
> Any ideas on what I can do to enable MySQL support in PHP? Using the
> RPM's only doesn't seem to work (though PHP by itself did). So I
> figured my last resort was to compile, but my ability to do that is
> very limited. All I have ever compiled is the linux kernal after one
> of our users meetings!
> Thanks,
> Mike Glaser