我正在尝试在本地机器上运行一个项目.我在 Mac OS 系统上安装了 Ruby 和 Rails.它工作正常.我可以创建一个新项目并且可以正常运行它而不会出现任何错误,但是当我尝试运行现有项目时,它说我们必须bundle install.当我运行该命令时,出现以下错误:
I am trying to run one project on my local machine. I installed Ruby and Rails on my Mac OS system. It is working properly. I can create a new project and can run it properly without any error, but when I try to run the existing project it says that we have to bundle install. When I run that command I get the following error:
"An error occurred while installing rmagick (2.13.2), and Bundler cannot continue. Make sure that `gem install rmagick -v '2.13.2'` succeeds before bundling."当我运行 gem install rmagick -v '2.13.2' 时,它给了我以下错误:
When I run gem install rmagick -v '2.13.2' it gives me the following error:
ERROR: Error installing rmagick: ERROR: Failed to build gem native extension. /usr/local/rvm/rubies/ruby-1.9.3-p392/bin/ruby extconf.rb checking for Ruby version >= 1.8.5... yes checking for gcc-4.2... yes checking for Magick-config... no Can't install RMagick 2.13.2. Can't find Magick-config in /usr/local/rvm/gems/ruby-1.9.3-p392/bin:/usr/local/rvm/gems/ruby-1.9.3-p392@global/bin:/usr/local/rvm/rubies/ruby-1.9.3-p392/bin:/usr/local/rvm/gems/ruby-1.9.3-p392/bin:/usr/local/rvm/gems/ruby-1.9.3-p392@global/bin:/usr/local/rvm/rubies/ruby-1.9.3-p392/bin:/usr/local/rvm/bin:/usr/bin:/bin:/usr/sbin:/sbin:/usr/local/bin:/opt/sm/bin:/opt/sm/pkg/active/bin:/opt/sm/pkg/active/sbin *** 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: --with-opt-dir --without-opt-dir --with-opt-include --without-opt-include=${opt-dir}/include --with-opt-lib --without-opt-lib=${opt-dir}/lib --with-make-prog --without-make-prog --srcdir=. --curdir --ruby=/usr/local/rvm/rubies/ruby-1.9.3-p392/bin/ruby Gem files will remain installed in /usr/local/rvm/gems/ruby-1.9.3-p392/gems/rmagick-2.13.2 for inspection. Results logged to /usr/local/rvm/gems/ruby-1.9.3-p392/gems/rmagick-2.13.2/ext/RMagick/gem_make.out我已经搜索过,但没有在任何地方找到答案.
I have searched and did not find an answer anywhere.
推荐答案对于 Ubuntu,我使用了 ff.基于此链接:
For Ubuntu, I used the ff. based on this link:
$ sudo apt-get install libmagick++-dev更多推荐
Rails:安装 rmagick 时出错
发布评论