Jump to content

undefined symbol mysql_set_character_set


lukinagin

Recommended Posts

I am running a Solaris 10 (SPARC) system that has Apache 2.2.6 and PHP v5.2.2 installed.  PHP is running as a CLI and not as an Apache module.  The system works fine.  I am now in the process of upgrading PHP to version 5.2.5 using the following configuration parameters:

 

./configure --prefix=/usr/local/php5 --with-openssl \

--with-oci8=instantclient,/usr/local/oracle/instantclient_10_2 \

--with-mysql=/usr/local/mysql --with-mysql-sock=/tmp/mysql.sock \

--with-zlib-dir=/usr/local/lib \

--enable-fastcgi --with-xsl \

--with-mcrypt=/usr/local/libmcrypt --enable-mbstring \

--with-ldap

 

The configure finishes fine but when I run make I get the following error:

 

Undefined                      first referenced

symbol                            in file

mysql_set_character_set            ext/mysql/php_mysql.o

ld: fatal: Symbol referencing errors. No output written to sapi/cgi/php-cgi

collect2: ld returned 1 exit status

*** Error code 1

make: Fatal error: Command failed for target `sapi/cgi/php-cgi'

 

I have MySQL version 5.0.37 installed on the system and running and I have both my PATH variables and LD_LIBRARY_PATH pointing to the appropriate MySQL directories.

 

Can someone shed some light on what this error is telling me and how I can fix it?

 

Thanks!

 

Jesse

 

Link to comment
https://forums.phpfreaks.com/topic/80194-undefined-symbol-mysql_set_character_set/
Share on other sites

I did some more troubleshooting and narrowed this issue down to this parameter in my configure line:

 

--with-openssl

 

As soon as I removed this line, my configure and make both worked flawlessly (go figure).  I then changed the --with-openssl to --with-openssl=/usr/local/ssl and reran through the steps.  Everything worked! 

 

It looks like the mysql_set_character_set message was sending me in the wrong direction. 

 

Live and learn.

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.