1

I am trying to run a ruby program that requires DL. It was written for ruby 1.9.3-p392 and I have tried it on 1.9.3-p392, 1.9.3-p484, 1.9.3-p547 -- all installed via rbenv on a new MBP running Mavericks. (It worked on my last machine, but not this new machine)

The error I am getting is as follows:

>> require 'dl'
MissingSourceFile: cannot load such file -- dl
from /Users/user/.rbenv/versions/1.9.3-p547/lib/ruby/gems/1.9.1/gems/activesupport-2.3.18/lib/active_support/dependencies.rb:182:in `require'

I have tried reinstalling ruby versions and compiling with gcc instead of clang as detailed in "Spring doesn't work. [ uninitialized constant Spring::SID::DL ]", which seemed similar, but did not help.

The program works fine on co-workers machines, so I know there isn't a code error. (Also I should be able to do a require 'dl' from the console.)

I have tried manually doing a gem install dl which works fine, but doesn't fix the problem.

Community
  • 1
  • 1
  • You're on Mac OS, not Windows, but http://stackoverflow.com/q/15590450/128421 and the related links on the right side of the page might shed some light on the problem. If the problem only occurs on your machine that means something is missing. I'd suggest figuring out what libraries are installed and used by Ruby on yours vs. your coworker's machines. – the Tin Man Oct 09 '14 at 15:34
  • Thanks. Unfortunately DL is part of Ruby's stdlib in 1.9.3 so I'm not entirely clear why it would be missing or how to install it, without simply reinstalling and recompiling ruby, which i have done a few times now. Clearly what I am missing and what they have is the DL library ('require dl' works fine on their systems), but I don't know why – Bitcruncher Oct 09 '14 at 15:45
  • DL might be there, but underlying prerequisites could be missing. When they are, you have to watch the compile log closely to see if anything shows up as missing. – the Tin Man Oct 09 '14 at 17:29

0 Answers0