具有Snow Leopard和mysql2 gem问题的MySQL 5.5.8

我已经成功安装了MySQL 5.5.8和mysql2 gem 0.2.6。 但是当我执行rake db:create it告诉我:

dlopen(/Library/Ruby/Gems/1.8/gems/mysql2-0.2.6/lib/mysql2/mysql2.bundle, 9): Library not loaded: /usr/local/mysql/lib/libmysqlclient.16.dylib
  Referenced from: /Library/Ruby/Gems/1.8/gems/mysql2-0.2.6/lib/mysql2/mysql2.bundle
  Reason: Incompatible library version: mysql2.bundle requires version 17.0.0 or later, but libmysqlclient.16.dylib provides version 16.0.0 - /Library/Ruby/Gems/1.8/gems/mysql2-0.2.6/lib/mysql2/mysql2.bundle
/Users/vvdpzz/mayday/Rakefile:4
(See full trace by running task with --trace)

我该怎么办? 如何解决这个问题?


尝试像这样:sudo install_name_tool -change libmysqlclient.18.dylib /usr/local/mysql/lib/libmysqlclient.18.dylib〜/ .rvm / gems / ruby​​-1.8.7 / gems / mysql2-0.2.6 / lib / mysql2 / mysql2.bundle


rails server无法在OSX 10.6.5上使用rvm&ruby 1.9.2-p0启动mysql2

链接地址: http://www.djcxy.com/p/33241.html

上一篇: MySQL 5.5.8 with Snow Leopard and mysql2 gem problem

下一篇: Ruby gem mysql2 install failing