Topic: MySQL Native Bindings

I was setting up everything (properly, no more locomotive/MAMP for me, as i got sick of the weird config the more i learned) using … ysql_tiger

Im no unix/server geek, thought i made a huge mistake once but i was wrong...

anwyays, i get to the last part of the setup, which suggest MySQL native binding to speed up rails apps... … sql-rails/
and I got this:

blinking8s:~ blinking8s$ sudo gem install mysql -- --with-mysql-dir=/usr/local/mysql
Select which gem to install for your platform (i686-darwin8.7.1)
1. mysql 2.7.1 (mswin32)
2. mysql 2.7 (ruby)
3. mysql 2.6 (ruby)
4. mysql 2.5.1 (ruby)
5. Cancel installation
> 2
Building native extensions.  This could take a while...
*** 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.

Provided configuration options:

ERROR:  While executing gem ... (RuntimeError)
    ERROR: Failed to build gem native extension.
Gem files will remain installed in /usr/local/lib/ruby/gems/1.8/gems/mysql-2.7 for inspection.

Results logged to /usr/local/lib/ruby/gems/1.8/gems/mysql-2.7/gem_make.out

i read through the link posted above and notices other users were having the same error, but...i just dont understand their way to fix it. I googled stuff, hardly anything remotely dated...i tried a few of the mentions, nothing...

any ideas?

also...on my mysql prefs pane in system profs (OSX 10.4.7) i have no way to stop the mysql server it appearts, the button just says "start mysql server" and that the instance is running below it...

I repaired the mysql server stop/start didnt finish the install before i ran the pane install...dumb me. dont know how that happened...reinstall worked fine it seems.

Last edited by blinking8s (2006-08-07 07:30:37)


Re: MySQL Native Bindings

Do you have Developer Tools installed?

Most code examples are usually pulled out of the air and not tested. Use at your own risk!

Re: MySQL Native Bindings

yes, ive installed the xcode tools off my osx disc, which was the latest version


Re: MySQL Native Bindings

Hmm, did you follow every step of the Hivelogic article to the letter? I've done it several times in the past and haven't had any problems. Did you install MySQL and set the path in .bash_login/.bash_profile and open a new terminal window after that?

When in doubt, try restarting. It shouldn't be needed, but it doesn't hurt to try.

Railscasts - Free Ruby on Rails Screencasts

Re: MySQL Native Bindings

sure enough, i just took a step back today after a reboot, and it worked...who knows what i messed up, something trying to follow the directions too closely tricks my mind i guess...

thanks for the help