error pureftpd compiling with mysql

From WebHostingNeeds.com
Jump to: navigation, search

I am trying to install pure-ftpd with mysql support.

./configure --with-mysql --with-uploadscript --with-extauth

When i run configure, i get following error

checking for mysql_init in -lmysqlclient... yes
checking whether mysql clients can run... no
configure: error: Your MySQL client libraries aren't properly installed

MySQL is installed from source and is available

[[email protected] pure-ftpd-1.0.21]# find / -name '*mysqlclient*'
/usr/lib/mysql/libmysqlclient.so.16.0.0
/usr/lib/mysql/libmysqlclient.la
/usr/lib/mysql/libmysqlclient_r.so.16.0.0
/usr/lib/mysql/libmysqlclient_r.la
/usr/lib/mysql/libmysqlclient.so.16
/usr/lib/mysql/libmysqlclient.a
/usr/lib/mysql/libmysqlclient_r.so
/usr/lib/mysql/libmysqlclient.so
/usr/lib/mysql/libmysqlclient_r.so.16
/usr/lib/mysql/libmysqlclient_r.a
/usr/local/src/mysql-5.1.23-ndb-6.2.15/libmysql/libmysqlclient.la
/usr/local/src/mysql-5.1.23-ndb-6.2.15/libmysql/.libs/libmysqlclient.so.16.0.0
/usr/local/src/mysql-5.1.23-ndb-6.2.15/libmysql/.libs/libmysqlclient.la
/usr/local/src/mysql-5.1.23-ndb-6.2.15/libmysql/.libs/libmysqlclient.lai
/usr/local/src/mysql-5.1.23-ndb-6.2.15/libmysql/.libs/libmysqlclient.so.16
/usr/local/src/mysql-5.1.23-ndb-6.2.15/libmysql/.libs/libmysqlclient.a
/usr/local/src/mysql-5.1.23-ndb-6.2.15/libmysql/.libs/libmysqlclient.so
/usr/local/src/mysql-5.1.23-ndb-6.2.15/libmysql_r/libmysqlclient_r.la
/usr/local/src/mysql-5.1.23-ndb-6.2.15/libmysql_r/.libs/libmysqlclient_r.lai
/usr/local/src/mysql-5.1.23-ndb-6.2.15/libmysql_r/.libs/libmysqlclient_r.so.16.0.0
/usr/local/src/mysql-5.1.23-ndb-6.2.15/libmysql_r/.libs/libmysqlclient_r.la
/usr/local/src/mysql-5.1.23-ndb-6.2.15/libmysql_r/.libs/libmysqlclient_r.so
/usr/local/src/mysql-5.1.23-ndb-6.2.15/libmysql_r/.libs/libmysqlclient_r.so.16
/usr/local/src/mysql-5.1.23-ndb-6.2.15/libmysql_r/.libs/libmysqlclient_r.a
[[email protected] pure-ftpd-1.0.21]#

[[email protected] pure-ftpd-1.0.21]# uname -a
Linux server70.hosthat.com 2.6.18-53.el5 #1 SMP Mon Nov 12 02:14:55 EST 2007
x86_64 x86_64 x86_64 GNU/Linux
[[email protected] pure-ftpd-1.0.21]# mysql --version
mysql  Ver 14.14 Distrib 5.1.23-ndb-6.2.15, for redhat-linux-gnu (x86_64)
using  EditLine wrapper
[[email protected] pure-ftpd-1.0.21]#

How do i fix the error ?


SOLUTION

And what does "ldconfig -p|grep mysql" says ?

[[email protected] ~]# ldconfig -p|grep mysql
[[email protected] ~]#

i added /usr/lib/mysql to /etc/ld.so.conf, run ldconfig and it fixed the problem.


echo >> /etc/ld.so.conf
echo "/usr/lib/mysql" >>  /etc/ld.so.conf
ldconfig

After doing this, ldconfig -p start showing mysql library

# ldconfig -p|grep mysql
    libmysqlclient_r.so.15 (libc6,x86-64) => /usr/lib64/libmysqlclient_r.so.15
    libmysqlclient_r.so (libc6,x86-64) => /usr/lib64/libmysqlclient_r.so
    libmysqlclient.so.15 (libc6,x86-64) => /usr/lib64/libmysqlclient.so.15
    libmysqlclient.so (libc6,x86-64) => /usr/lib64/libmysqlclient.so
#