开发者

require 'ruby-debug' LoadError: symbol not found

开发者 https://www.devze.com 2023-01-10 07:01 出处:网络
I\'ve somehow broken my ruby configuration, and I\'m not sure how to fix it.Here\'s an irb session: >> require \'ruby-debug\'

I've somehow broken my ruby configuration, and I'm not sure how to fix it. Here's an irb session:

>> require 'ruby-debug'
LoadError: dlsym(0x101a272d0, Init_ruby_debug): symbol not found - /opt/local/lib/ruby/gems/1.8/gems/ruby-debug-base-0.10.3/lib/ruby_debug.bundle
        from /opt/local/lib/ruby/gems/1.8/gems/ruby-debug-base-0.10.3/lib/ruby_debug.bundle
        from /opt/local/lib/ruby/site_ruby/1.8/rubygems/custom_require.rb:31:in `require'
        from /opt/local/lib/ruby/gems/1.8/gems/ruby-debug-base-0.10.3/lib/ruby-debug-base.rb:1
        from /opt/local/lib/ruby/site_ruby/1.8/rubygems/custom_require.rb:31:in `gem_original_require'
        from /opt/local/lib/ruby/site_ruby/1.8/rubygems/custom_requi开发者_Go百科re.rb:31:in `require'
        from /opt/local/lib/ruby/gems/1.8/gems/ruby-debug-0.10.3/cli/ruby-debug.rb:5
        from /opt/local/lib/ruby/site_ruby/1.8/rubygems/custom_require.rb:36:in `gem_original_require'
        from /opt/local/lib/ruby/site_ruby/1.8/rubygems/custom_require.rb:36:in `require'
        from (irb):1

Here's my ruby version:

ruby 1.8.7 (2010-06-23 patchlevel 299) [i686-darwin10]

I'm not sure how to go about diagnosing and fixing this. Any suggestions? What other info should I provide?

Reinstalling the gem didn't fix it:

$ sudo gem install ruby-debug 
Password:
Successfully installed ruby-debug-0.10.3
1 gem installed
Installing ri documentation for ruby-debug-0.10.3...
Installing RDoc documentation for ruby-debug-0.10.3...


maybe it's missing some dependency .so file? I would use ldd -l to determine this in linux, dunno about mac.


Doing a fresh install of 1.8.7 via rvm fixed this problem for me.

0

精彩评论

暂无评论...
验证码 换一张
取 消