View Single Post
  #1  
Old 8th April 2008, 18:49
asyadiqin asyadiqin is offline
Senior Member
 
Join Date: Jul 2006
Posts: 120
Thanks: 0
Thanked 1 Time in 1 Post
Default Problem Installing Apache 2.2.8, MySQL 5.0 Client and PHP 5.2.5 On Fedora 8 (64-Bit)

I am trying to install the following :-

Apache 2.2.8 (64-Bit)
MySQL Client 5.0 (64-Bit)
PHP 5.2.5 (64-Bit)

I managed to install Apache and MySQL Client using yum, but had to compile PHP 5.2.5 as the current yum package only list PHP 5.2.4. (Note: My manager insisted that I install these versions, ie. PHP 5.2.5, etc... so no point telling me to stick to the current older versions )

Anyway, everything goes smoothly with Apache and MySQL Client, but when I try to compile PHP, it gave me errors. This is how I compile PHP

Quote:
./configure \
--prefix=/usr/bin \
--disable-xmlreader \
--disable-xmlwriter \
--enable-posix \
--with-pear \
--with-zlib \
--with-xml \
--with-zlib-dir=/usr \
--with-openssl \
--with-gd \
--with-jpeg-dir=/usr/lib64 \
--with-png-dir=/usr/lib64 \
--with-freetype-dir=/usr/lib64 \
--with-ttf \
--with-iconv \
--with-curl \
--enable-track_vars \
--enable-gd \
--enable-gd-native-ttf \
--enable-libxml \
--enable-dom \
--enable-simplexml \
--enable-exif \
--enable-ftp \
--enable-mbstring \
--enable-mbregex \
--enable-sockets \
--enable-embedded-mysqli \
--enable-memcache=/usr/bin \
--with-mysql=/usr/lib64/mysql \
--with-mysqli=/usr/bin/mysql_config \

--with-apxs2=/usr/sbin/apxs \
This is the error that I get ....

Quote:
......
checking for MING support... no
checking for mSQL support... no
checking for MSSQL support via FreeTDS... no
checking for MySQL support... yes
checking for specified location of the MySQL UNIX socket... no
checking for MySQL UNIX socket location... no
configure: error: Cannot find libmysqlclient under /usr.
Note that the MySQL client library is not bundled anymore!
I googled and found a site that suggested that I make the symlinks below and to change the compile options to --with-mysql=/opt

Quote:
ln -s /usr/lib64/ /opt/lib
ln -s /usr/include/ /opt/include
This is the error that I get when I compile it after that.
Quote:
checking for MING support... no
checking for mSQL support... no
checking for MSSQL support via FreeTDS... no
checking for MySQL support... yes
checking for specified location of the MySQL UNIX socket... no
checking for MySQL UNIX socket location... no
checking for mysql_close in -lmysqlclient... yes
checking for MySQLi support... yes
checking whether to enable embedded MySQLi support... yes
checking for mysql_set_server_option in -lmysqlclient... no
configure: error: wrong mysql library version or lib not found. Check config.log for more information.
This is what is in config.log
Quote:
.....
configure:60521: checking for MySQLi support
configure:60568: checking whether to enable embedded MySQLi support
configure:60719: checking for mysql_set_server_option in -lmysqlclient
configure:60738: gcc -o conftest -I/usr/local/include -g -O2 -Wl,-rpath,/usr/lib64 -L/usr/lib64 -Wl,-rpath,/usr/lib64/mysql -L/usr/lib64/mysql -L/usr/local/lib -Wl,-rpath,/usr/kerberos/lib64 -L/usr/kerberos/lib64 -Wl,-rpath,/opt/lib/mysql -L/opt/lib/mysql -lmysqld -lz -lcrypt -lnsl -lm -lrt -lssl -lcrypto conftest.c -lmysqlclient -lmysqlclient -lfreetype -lpng -lz -ljpeg -lcurl -lz -lresolv -lm -ldl -lnsl -lxml2 -lz -lm -lssl -lcrypto -ldl -lz -lcurl -lxml2 -lz -lm -lssl -lcrypto -ldl -lz 1>&5
/usr/bin/ld: cannot find -lmysqld
collect2: ld returned 1 exit status
configure: failed program was:
#line 60727 "configure"
#include "confdefs.h"
/* Override any gcc2 internal prototype to avoid an error. */
/* We use char because int might match the return type of a gcc2
builtin and then its argument prototype would still apply. */
char mysql_set_server_option();

int main() {
mysql_set_server_option()
; return 0; }
FYI, I installed the following MySQL packages using yum
Quote:
mysql - 5.0.45-6.fc8.x86_64
mysql-devel - 5.0.45-6.fc8.x86_64
mysql-libs - 5.0.45-6.fc8.x86_64
mysql-bench - 5.0.45-6.fc8.x86_64
Anyone have any idea what I did wrong or is there any missing package that I should install first?

It would be good if someone were to write a "Howto Guide" to install LAMP from source rather than using yum. I'm sure there are many who would like that as yum have its limitations, ie. older packages, etc...

Thanks and hope someone can help me with this problem.
Reply With Quote
Sponsored Links