Home > article > Macでgem install mysqlをする方法

Macでgem install mysqlをする方法

Rails2.2からmysqlのアダプタが付属していないので各個人でインストールする必要があります。gemで入れようとするとエラーがでると思うので以下のように対応してください。

$ sudo gem install mysql
$ cd /opt/local/lib/ruby/gems/1.8/gems/mysql-2.7/
$ sudo ruby extconf.rb --with-mysql-config=/opt/local/lib/mysql5/bin/mysql_config
$ sudo make
$ sudo make install

パスに関しては、人によって違うかもしれませんが適宜読み替えてください。

追記

$ sudo gem install mysql -- --with-mysql-config=/opt/local/lib/mysql5/bin/mysql_config

これでも大丈夫らしい。

Comments:4

Maybell Poff 11-10-30 (Sun) 4:35

Wow! This blog looks just like my old one! It’s on a totally different topic but it has pretty much the same layout and design. Great choice of colors! Bless you!

Dominique Bella 11-10-31 (Mon) 1:06

I always was concerned in this topic and stock still am, appreciate it for posting . Thanx.

Tyler Saylee 11-10-31 (Mon) 4:33

Good day! Do you know if they make any plugins to assist with Search Engine Optimization? I’m trying to get my blog to rank for some targeted keywords but I’m not seeing very good success. If you know of any please share. Cheers!

Na Harbaugh 11-10-31 (Mon) 9:31

I believe this website holds very excellent composed content material blog posts. Thank you.

Comment Form
Remember personal info

Trackbacks:0

Trackback URL for this entry
http://ukstudio.jp/2008/11/27/mac_gem_install_mysql/trackback/
Listed below are links to weblogs that reference
Macでgem install mysqlをする方法 from UKSTUDIO

Home > article > Macでgem install mysqlをする方法

Feeds
Meta
Others

Return to page top