Skip to content

Fusion Network

Ruby on Rails and Rmagick Problems

Have problems with Rmagick and Ruby on Rails?

libMagickCore.so.1: cannot open shared object file: No such file or directory RMagick2.so

Read more for the fix...


 /usr/local/ruby-enterprise/lib/ruby/gems/1.8/gems/rmagick-2.5.2/lib/RMagick2.so /usr/local/ruby-enterprise/lib/ruby/site_ruby/1.8/rubygems/custom_require.rb:32:in `require' /usr/local/ruby-enterprise/lib/ruby/gems/1.8/gems/activesupport-2.1.0/lib/active_support/dependencies.rb:509:in `require' /usr/local/ruby-enterprise/lib/ruby/gems/1.8/gems/activesupport-2.1.0/lib/active_support/dependencies.rb:354:in `new_constants_in' /usr/local/ruby-enterprise/lib/ruby/gems/1.8/gems/activesupport-2.1.0/lib/active_support/dependencies.rb:509:in `require' /usr/local/ruby-enterprise/lib/ruby/gems/1.8/gems/rmagick-2.5.2/lib/RMagick.rb:11 /usr/local/ruby-enterprise/lib/ruby/site_ruby/1.8/rubygems/custom_require.rb:32:in `gem_original_require' /usr/local/ruby-enterprise/lib/ruby/site_ruby/1.8/rubygems/custom_require.rb:32:in `require' /usr/local/ruby-enterprise/lib/ruby/gems/1.8/gems/activesupport-2.1.0/lib/active_support/dependencies.rb:509:in `require' /usr/local/ruby-enterprise/lib/ruby/gems/1.8/gems/activesupport-2.1.0/lib/active_support/dependencies.rb:354:in `new_constants_in' /usr/local/ruby-enterprise/lib/ruby/gems/1.8/gems/activesupport-2.1.0/lib/active_support/dependencies.rb:509:in `require' vendor/plugins/file_column/lib/magick_file_column.rb:208:in `file_column' vendor/plugins/file_column/lib/file_column.rb:698:in `file_column' app/models/profile.rb:74 app/controllers/application.rb:13:in `check_featured' app/controllers/home_controller.rb:15:in `index'

From my experience this is because a problem with LD_LIBRARY_PATH. Before you install Rmagick run this command.

}export LD_LIBRARY_PATH="/usr/local/lib"

Next Run the "gem install rmagick".
Your app should be happy with rmagick now!