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
Share on other sites

This thread is more than a year old. Please don't revive it unless you have something important to add.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • 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.