Jump to content

Build Error with MySQL


Recommended Posts

Hi All,

 

I am trying to install PHP with mysql database on Solaris 5.8 and I find my OS is 64 bit but on mysql site I only find MySQL 5.1 database for 32 bit, anyway I installed and mysql is working fine for my other application but when i try to install php and run the following command

 

  ./configure --with-libxml-dir=/usr/local --with-xsl=/usr/lib --with-mysql=/usr/local/mysql --with-apxs=/usr/apache/bin/apxs --with-zlib-dir

 

it always gives an error and when i checked the config.log file I got the following lines at the bottom of the file

 

 

configure:59851: checking for mysql_error in -lmysqlclient

configure:59870: gcc -o conftest -I/usr/local/include -g -O2  -D_POSIX_PTHREAD_S

EMANTICS -R/usr/local/mysql/lib -L/usr/local/mysql/lib -liconv -L/usr/local/lib

-R/usr/ucblib -L/usr/ucblib -R/usr/local/lib/gcc/sparc-sun-solaris2.8/3.4.2 -L/

usr/local/lib/gcc/sparc-sun-solaris2.8/3.4.2 -R/usr/local/lib -L/usr/local/lib -

R/usr -L/usr conftest.c -lmysqlclient  -lz -liconv -lz -lresolv -lm -ldl -lnsl -

lsocket  -lgcc -lxml2 -lz -liconv -lm -lsocket -lnsl -lxml2 -lz -liconv -lm -lso

cket -lnsl 1>&5

ld: fatal: file /usr/local/mysql/lib/libmysqlclient.so: wrong ELF class: ELFCLAS

S64

ld: fatal: File processing errors. No output written to conftest

collect2: ld returned 1 exit status

configure: failed program was:

#line 59859 "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_error();

 

int main() {

mysql_error()

; return 0; }

 

I have been trying to install PHP and I went through so many forum but couldn't find the answer and I am trying my luck here as well if somebody could help me.

 

Regards,

Nauman

Link to comment
https://forums.phpfreaks.com/topic/129775-build-error-with-mysql/
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.