2011-03-10 4 views
1

Je suis en train d'installer la pierre précieuse mysql viane peut pas exécuter installer Fedora 14 gem MySQL, même après l'installation de MySQL-devel, ruby-devel et rubygems

sudo gem install mysql --version 2.7 

Cependant, je reçois l'erreur suivante :

Building native extensions. This could take a while... 
........... 
ERROR: Error installing mysql: 
    ERROR: Failed to build gem native extension. 

/usr/bin/ruby extconf.rb 
checking for mysql_query() in -lmysqlclient... no 
checking for main() in -lm... yes 
checking for mysql_query() in -lmysqlclient... no 
checking for main() in -lz... yes 
checking for mysql_query() in -lmysqlclient... no 
checking for main() in -lsocket... no 
checking for mysql_query() in -lmysqlclient... no 
checking for main() in -lnsl... yes 
checking for mysql_query() in -lmysqlclient... no 
*** extconf.rb failed *** 
Could not create Makefile due to some reason, probably lack of 
necessary libraries and/or headers. Check the mkmf.log file for more 
details. You may need configuration options. 

Des idées?

Répondre

2

somethings à essayer:

gem install mysql -- --with-mysql-config=/usr/local/mysql/bin/mysql_config 

de chemin d'utilisation bien sûr de l'endroit où votre mysql_config est. mysql_config sera là si vous avez installé un client MySQL

gem install mysql -- \ 
--with-mysql-include=/usr/include/mysql \ 
--with-mysql-lib=/usr/lib/mysql 

chemins d'utilisation de l'endroit où votre lib et en-têtes sont pour mysql.

+0

'sudo gem installer MySQL - --version 2.7 --with-mysql-dir =/usr/local/mysql' avons réussi, (. Effectivement installé 2.8 v, idk pourquoi) – jonderry

Questions connexes