安装rails时遇到的问题汇总



1.Could not find gem 'rmagick (>= 2.0.0) ruby' in the gems available on this machine. (Bundler::GemNotFound)


gem 安装rmagick时会报错


Can't install RMagick 2.13.1. Can't find Magick-config in /usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/var/yr/truck/yrservice


*** 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.


解决: apt-get install graphicsmagick-libmagick-dev-compat
然后又报:Can't install RMagick 2.13.1. Can't find MagickWand.h.
解决办法:apt-get install imagemagick   apt-get install libmagickwand-dev graphicsmagick-imagemagick-compat
然后再gem install rmagick


2.Please install the mysql adapter: `gem install activerecord-mysql-adapter` (can't activate mysql (~> 2.8.1, runtime), already activated mysql-2.9.0. Make sure all dependencies are added to Gemfile.)

/var/www/redmine/lib/plugins/acts_as_activity_provider/init.rb:2
/var/www/redmine/config/initializers/00-core_plugins.rb:12
/var/www/redmine/config/initializers/00-core_plugins.rb:2:in `each'
/var/www/redmine/config/initializers/00-core_plugins.rb:2
/var/www/redmine/config/environment.rb:14
Tasks: TOP => db:migrate => environment
(See full trace by running task with --trace)


更改Gemfile


评论 1
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值