[Rubygems-developers] How to deal with binary dependencies?

Charlie Savage cfis at savagexi.com
Mon Jul 21 14:57:29 EDT 2008

> So, that means is good to put the DLLs in ruby/bin, like One-Click
> Installer is doing.

Yes, I think that is the right choice for the one click installer.

For an individual GEM, I think either solution is ok - a) copying the 
shared library to ruby/bin or b) manipulating the path to add the path 
the shared library

> Right now RubyGems offer you a mechanism that set stubs in ruby/bin,
> but that procedure doesn't like executables or even shared libraries
> (dll):
> http://rubyforge.org/pipermail/rubygems-developers/2007-October/003123.html
> Since we already have #executables and #bindir to define where those
> are inside our gems.
> What about #binaries? and we thread them different that executables
> (verbatim copy them instead of adding shebangs).

I'd probably be more specific and define a new spec setting called 
"libraries" that means RubyGems will:

a) On installation copy the files marked "libraries" to ruby/bin
b) On loading a gem, update the path to include the location of the 
library files (if any are set).





spec.libraries << "lib/libxml2-2.dll"

How does that sound?

And what should I do in the short term?

-------------- next part --------------
A non-text attachment was scrubbed...
Name: smime.p7s
Type: application/x-pkcs7-signature
Size: 3237 bytes
Desc: S/MIME Cryptographic Signature
URL: <http://rubyforge.org/pipermail/rubygems-developers/attachments/20080721/4f3478ad/attachment.bin>

More information about the Rubygems-developers mailing list