brianpuccio.net

it's dot com

Installing Ruby's MySQL Gem With MySQL Installed Via Fink

Date: Tuesday, March 4, 2008 - 9:51pm
Keywords: Ruby, OS X, mysql, fink
Links:


If you've installed MySQL via fink and you're going to install the MySQL gem for Ruby and you're getting something like this:

Macintosh:~ brianpuccio$ sudo gem install mysql
Building native extensions.  This could take a while...
ERROR:  Error installing mysql:
	ERROR: Failed to build gem native extension.

/System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/bin/ruby extconf.rb install mysql -- --with-mysql-dir=/sw/var/mysql/
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... no
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.

The command you really need is sudo gem install mysql -- --with-mysql-config=/opt/local/lib/mysql5/bin/mysql_config

Post new comment

The content of this field is kept private and will not be shown publicly.
  • Allowed HTML tags: <a> <em> <strong> <cite> <code> <ul> <ol> <li> <dl> <dt> <dd> <pre> <blockquote> <img> <h1> <h2> <h3> <h4> <del> <ins>
  • Lines and paragraphs break automatically.

More information about formatting options

Syndicate

Syndicate content

User login