0

I have a Ruby C extension that is providing a ruby interface to use a third part C library. I am able to build the library, let's call it something.so just fine. However, it's compiled against the third party .lib and .dll files dynamically.

When I actually try to run a ruby script that has

require 'something'

it fails. Ruby doesn't know how to find the DLLs the something.so was linked against. It gives me an error like:

---------------------------
ruby.exe - System Error
---------------------------
The program can't start because SomeThirdParty.dll is missing from your computer. Try    reinstalling the program to fix this problem. 
---------------------------
OK   
---------------------------

What do I need to do to tell ruby how to find this dll? If I put all the third party dlls in the same directory as the ruby script I'm running it works, but I'd rather not do that.

ZombieDev
  • 959
  • 1
  • 10
  • 25

1 Answers1

1

Just put it in a place that is inside your PATH. A good place may be the ruby\bin directory.

Guilherme Bernal
  • 8,183
  • 25
  • 43