Ruby Tips 11: Install mysql gem on Mac OS X Lion

21 sec read

[source]brew install mysql[/source]
Is you have installed mysql server already and have a failed mysql gem, then remove the mysql server first [ see]
Do this to install mysql system tables:
[source]
mysql_install_db –verbose –user=`whoami` –basedir=”$(brew –prefix mysql)” –datadir=/usr/local/var/mysql –tmpdir=/tmp
[/source]
Install mysql gem:
[source]
sudo env ARCHFLAGS=”-arch x86_64″ gem install mysql — –with-mysql-dir=/usr/local/Cellar/mysql –with-mysql-lib=/usr/local/Cellar/mysql/5.5.15/lib/ –with-mysql-include=/usr/local/mysql/5.5.15/include –with-mysql-config=/usr/local/Cellar/mysql/5.5.15/bin/mysql_config
[/source]
To find out what your machine is. use uname -a

Related posts:

My Testing Experience with Healthcare Project

Hi Folks, I am working on a healthcare related web application. I would like to share few interesting things that I came across while...
Ashwin Sundarabaskar
5 min read

Fix for Net::OpenTimeout: execution expired When on AWS with…

If you happen to see the error “Net::OpenTimeout: execution expired” and if it originating from /home/ubuntu/.rvm/rubies/ruby-x.x.x/lib/ruby/x.x.x/net/smtp.rb and if you are running your server on...
Praveen Kumar
15 sec read

Speaking at Ruby meetups – a way of giving…

Speaking at meetups is a great way of giving back to the community and so we always encourage our mates at Spritle to be...
Spritle Bot
1 min read

One Reply to “Ruby Tips 11: Install mysql gem on Mac OS…”

Leave a Reply

Your email address will not be published. Required fields are marked *