[Rubygems-developers] Re: [Wxruby-users] RubyGems and wxRuby

Chad Fowler chad at chadfowler.com
Fri Apr 16 07:32:22 EDT 2004

On 15/4/2004, at 11:50 PM, Curt Hibbs wrote:

> Richard Kilmer wrote:
>> On Apr 15, 2004, at 11:15 PM, Curt Hibbs wrote:
>>> So Rich, my question to you is this: Can I construct a RubyGem such
>>> that I
>>> can have several alternative, pre-built binaries, and get the correct
>>> one
>>> installed for the user's platform?
>>> Curt
>> I don't think you want to have a single gem with every binary in it, 
>> but
>> a gem binary for each platform.  Is that right?  I believe we have 
>> this
>> capability now...Chad???
> Yes, having a separate gem for each platform would be best.

That's the way to do it.  It works today, but the installer isn't smart 
enough to pick the right gem yet.  It should be trivial to add.  Just 
hasn't been done yet.

In testing this, I realized that if you do something like:

gem -Ri a

It won't ask you which matching gem to install.  It just matches /a/ 
and installs it.  Need to push this onto the TODO list (perhaps after I 
wake up this morning). :)

>> I know in the Gem spec you can specify the platform (win32, etc).  The
>> question is how does the installer deal with multiple available gems
>> (of the same name) but of different platforms.  Chad and I talked of
>> this, but I don't know the state of the implementation.
> I knew I might be pushing the envelop here!  :-)

As I said, I don't think it will be too difficult.  We need to figure 
out how to best match platforms (i686-linux, i586-linux, etc.) so that 
the slight ambiguities that exist don't make things unwieldy.  But you 
can definitely make platform-specific gems now and they should work.


More information about the Rubygems-developers mailing list