Patrick Hurley wrote:
> On 8/23/06, ryan.raaum / gmail.com <ryan.raaum / gmail.com> wrote:
> >
> > Patrick Hurley wrote:
> > > On 8/23/06, ryan.raaum / gmail.com <ryan.raaum / gmail.com> wrote:
> > > > Also, it is important to ask if you are on windows or linux/bsd/mac os
> > > > x.  It is significantly harder to extend ruby on windows than on one of
> > > > the unixy systems.
> > >
> > > Not really. It is significantly harder to build libraries designed for
> > > unixy systems under windows than on those unixy systems. But the Ruby
> > > interface to C/C++ is pretty much identical between platforms. Why do
> > > you say it is harder?
> >
> > Because ruby is unix focussed.  All the core ruby developers are unix
> > people.  The ruby toolchain is a unix-oriented toolchain (see the
> > recent 100+ message thread about ruby on windows).
> >
> > To build on windows, one must either build ruby from scratch using
> > mingw (a topic of some contention and basically a unix toolset for
> > windows) or have vc6, which is less than readily available if you don't
> > already have it.  Ruby does not build easily in currently available
> > microsoft tools.
> >
> > Starting from scratch, on a vanilla unix system, anyone with reasonable
> > unix and c knowledge can build ruby and a (minimal) custom extension in
> > well under an hour.
> >
> > Starting from scratch, on a vanilla windows system, I would be amazed
> > if a windows guru could build ruby and a custom extension in under a
> > full working day.
> >
> > >
> > > pth
> >
>
> I won't argue that building Ruby on Windows is somewhat difficult
> (well gathering the unixy tool chain for Windows takes some patience
> and then the build is pretty easy). But that is not necessary using
> the one-click ruby installer and VC6, building C/C++ extensions under
> windows from an already compiling library is really quite painless.

The key here is that you have a tool (VC6) which is not generally
available.  If one doesn't have this tool, as I don't, then extending
ruby on windows becomes much more challenging.

>
> To qualify I am a long time C/C++ developer under Windows and Linux.
> But I have not encountered any Window's issues with regard to
> extension building -- I have been very pleased with how easy it is to
> use mkmf under Windows (I plan on trying out the new rake based tool
> soon :-).
>
> Again if you are fighting with a unixy library or your library is
> inherently multi-threaded (like the Win32 service interface), then you
> will have some issues -- otherwise I find writing C extensions quite
> easy in both environments. Of course your mileage may vary.
> 
> pth