[Rubyinstaller-devel] rake-compiler

Luis Lavena luislavena at gmail.com
Thu Dec 4 22:28:20 EST 2008


On Thu, Dec 4, 2008 at 9:22 PM, Dominic Sisneros <dsisnero at gmail.com> wrote:
> I was trying to compile the curb gem and got it working after making some
> changes.  When trying to
> package it for windows from ubuntu intrepid I get the following error
> because the ruby in ubuntu is
> version 1.8.7 and I asked for the 1.8.6 version of ruby of ruby to
> cross-compile with

You should have then installed 1.8.7-p72 as cross compiler

rake-compiler cross-ruby VERSION=1.8.7-p72

By default rake-compiler will target the latest stable 1.8.6, since I
believe 1.8.7 is flawed and even more any OS that decide to ship it by
default.

My humble opinion, of course.

> dominics-linux:~/programming/repos/curb$ rake cross native gem
> (in /home/dominic/programming/repos/curb)
> cd tmp/i386-mswin32/curb_core
> ./rbconfig.rb:7: ruby lib version (1.8.6) doesn't match executable version
> (1.8.7) (RuntimeError)
>     from /usr/lib/ruby/1.8/mkmf.rb:4:in `require'
>     from /usr/lib/ruby/1.8/mkmf.rb:4
>     from /home/dominic/programming/repos/curb/ext/curb_core/extconf.rb:1:in
> `require'
>     from /home/dominic/programming/repos/curb/ext/curb_core/extconf.rb:1
> rake aborted!
> Command failed with status (1): [/usr/bin/ruby1.8 -I.
> /home/dominic/program...]
>
> (See full trace by running task with --trace)
>
> So, when running rake cross native gem it should somehow use the rake
> installed in ~/.rake-compiler
> directory `.rake-compiler/ruby/ruby-1.8.6-p287/bin directory
>

That defeats the purpose of cross compilation.

You cannot use that version of Ruby unless you have wine installed to
run under a Windows emulation.

Besides, there is no rake, gem or anything installed in the
cross-compiled ruby version that rake-compiler generated for you, it
is only used for linking and for grabbing the configuration
(rbconfig.rb) file.

Please try "rake-compiler clobber" and then specify the version of
Ruby you're using.

That should work.

Thank you for trying rake-compiler. I'll add a note about 1.8.6 versus
1.8.7 in the next release.

-- 
Luis Lavena
AREA 17
-
Human beings, who are almost unique in having the ability to learn from
the experience of others, are also remarkable for their apparent
disinclination to do so.
Douglas Adams


More information about the Rubyinstaller-devel mailing list