Is the mingw component now builtin to RubyInstaller?
The compiler environment (DevKit) is not bundled with the installer,
specifically because not all users will require to compile extensions.
Also, the DevKit is the same for MRI, YARV and (in future) JRuby. It
doesn’t make sense to either install, release or maintain separate
copies of the DevKit. Not because of the waste of disk space or
download bandwidth, but for the same software engineering reasons that
you always try to eliminate code duplication.
If you install, say, both JRuby and MRI, you still need only one copy
of the DevKit. This wouldn’t be possible, if it was built into the
respective installers.
Thanks, I understand now. So you install the DevKit (which contains
mingw) once. Then you can build gems with native extensions or other
extconf libraries.
Sorry if this is OT, but I’d also like to ask if this can work with
RVM. If you install the DevKit, can you then use rvm to install (and
presumably compile) other rubies?
Is the mingw component now builtin to RubyInstaller?
Well, yes, the versions of Ruby packaged in the current RubyInstallers
are compiled using the MinGW toolchain. It’s pretty cool how easy it
is to compile different versions of Ruby in Windows:
Then there’s the DevKit, which is a MinGW environment designed for
compiling Ruby C extensions (and other things):
Thanks, I understand now. So you install the DevKit (which contains
mingw) once. Then you can build gems with native extensions or other
extconf libraries.
Sorry if this is OT, but I’d also like to ask if this can work with
RVM. If you install the DevKit, can you then use rvm to install (and
presumably compile) other rubies?
No. DevKit is Windows only, and RVM is *nix only. You can however use
Pik GitHub - vertiginous/pik: Ruby version manager for Windows
Thanks, I understand now. So you install the DevKit (which contains
mingw) once. Then you can build gems with native extensions or other
extconf libraries.
Sorry if this is OT, but I’d also like to ask if this can work with
RVM. If you install the DevKit, can you then use rvm to install (and
presumably compile) Â other rubies?
DevKit works with Pik on Windows. IF you follow instructions on Development Kit · oneclick/rubyinstaller Wiki · GitHub DevKit
will be set up for each version of Ruby you have installed. You can
manually add other versions (see Step 4) too.
Sorry if this is OT, but I’d also like to ask if this can work with
RVM. If you install the DevKit, can you then use rvm to install (and
presumably compile) other rubies?
RVM is a series of Bash scripts that works for bash and *nix like
environments.
Pik is a similar tool that works directly from normal Windows command
prompt.
On Windows compilation of Ruby is a bit more complicated because none
of the Ruby dependencies like zlib or OpenSSL are provided by the OS.
RubyInstaller repository contains the list of recipes and the needed
changes to those dependencies to work.
Also, compilation of all the dependencies can take a lot of time (up
to 30 minutes on Core 2 Duo 2.2 GHz). I would recommend you use the
provided binaries instead.
If you have further questions, please bring them to RubyInstaller
group: