MySQL Gem installation
Posted by:
Dai Le
Date: March 26, 2009 02:52PM
Hi, I'm trying to installation the MySQL gem for Ruby and I keep getting this error that I have no idea how to resolve. Has anyone ever encountered this error or have an idea of how resolve it?
I'm issuing the command:
sudo gem install mysql -- --with-mysql-config=/usr/bin/mysql_config
and I get this output:
Building native extensions. This could take a while...
ERROR: Error installing mysql:
ERROR: Failed to build gem native extension.
/usr/bin/ruby extconf.rb install mysql -- --with-mysql-config=/usr/bin/mysql_config
checking for mysql_ssl_set()... no
checking for mysql.h... yes
creating Makefile
make
gcc -I. -I. -I/usr/lib64/ruby/1.8/x86_64-linux -I. -DHAVE_MYSQL_H -I/usr/include/mysql -g -pipe -Wp,-D_FORTIFY_SOURCE=2 -fexceptions -fstack-protector --param=ssp-buffer-size=4 -m64 -DUNIV_LINUX -fPIC -O2 -g -pipe -Wall -Wp,-D_FORTIFY_SOURCE=2 -fexceptions -fstack-protector --param=ssp-buffer-size=4 -m64 -mtune=generic -Wall -fno-strict-aliasing -fPIC -c mysql.c
mysql.c: In function âmake_field_objâ:
mysql.c:185: warning: unused variable âhashâ
mysql.c: In function âstmt_executeâ:
mysql.c:1316: warning: unused variable âfalseâ
mysql.c: In function âtime_inspectâ:
mysql.c:1708: warning: format â%04dâ expects type âintâ, but argument 5 has type âlong intâ
mysql.c:1708: warning: format â%02dâ expects type âintâ, but argument 6 has type âlong intâ
mysql.c:1708: warning: format â%02dâ expects type âintâ, but argument 7 has type âlong intâ
mysql.c:1708: warning: format â%02dâ expects type âintâ, but argument 8 has type âlong intâ
mysql.c:1708: warning: format â%02dâ expects type âintâ, but argument 9 has type âlong intâ
mysql.c:1708: warning: format â%02dâ expects type âintâ, but argument 10 has type âlong intâ
mysql.c: In function âtime_to_sâ:
mysql.c:1721: warning: format â%04dâ expects type âintâ, but argument 5 has type âlong intâ
mysql.c:1721: warning: format â%02dâ expects type âintâ, but argument 6 has type âlong intâ
mysql.c:1721: warning: format â%02dâ expects type âintâ, but argument 7 has type âlong intâ
mysql.c:1721: warning: format â%02dâ expects type âintâ, but argument 8 has type âlong intâ
mysql.c:1721: warning: format â%02dâ expects type âintâ, but argument 9 has type âlong intâ
mysql.c:1721: warning: format â%02dâ expects type âintâ, but argument 10 has type âlong intâ
mysql.c: In function âtime_initializeâ:
mysql.c:1703: warning: control reaches end of non-void function
mysql.c: In function âstmt_executeâ:
mysql.c:1365: warning: ât.time_typeâ is used uninitialized in this function
mysql.c:1378: warning: ât.time_typeâ is used uninitialized in this function
gcc -shared -L"/usr/lib64" -o mysql.so mysql.o -lruby -rdynamic -L/usr/lib64/mysql -lmysqlclient -lz -lcrypt -lnsl -lm -lmygcc -lpthread -ldl -lcrypt -lm -lc
/usr/bin/ld: cannot find -lruby
collect2: ld returned 1 exit status
make: *** [mysql.so] Error 1
Gem files will remain installed in /usr/lib64/ruby/gems/1.8/gems/mysql-2.7 for inspection.
Results logged to /usr/lib64/ruby/gems/1.8/gems/mysql-2.7/gem_make.out
Subject
Written By
Posted
MySQL Gem installation
March 26, 2009 02:52PM
Sorry, you can't reply to this topic. It has been closed.
Content reproduced on this site is the property of the respective copyright holders.
It is not reviewed in advance by Oracle and does not necessarily represent the opinion
of Oracle or any other party.