-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Am 11.05.2011 09:56, schrieb Arne De Herdt:
> Hello,
> 
> I'm currently busy compiling several gems from source on my Windows
> platform. Yes, you've read that right, W-I-N-D-O-W-S platform :)
> 
> Most of the gems and ruby code is compiling without issues, but
> sometimes I encounter gems that have native extensions that need to be
> build. To give the example i'm currently working on : Thin
> 
> Thin is relying on rake to do the configuration and installation, and
> here is the problem (also occurs with make tbh). Let me copy&paste a
> small piece from the Makefile generated by thin:
> 
> #### Start of system configuration section. ####
> 
> srcdir = /C/Source/git/thin/ext/thin_parser
> topdir = /C/Ruby/include/ruby-1.9.1
> hdrdir = /C/Ruby/include/ruby-1.9.1
> arch_hdrdir = C:/Ruby/include/ruby-1.9.1/$(arch)
> VPATH = $(srcdir):$(arch_hdrdir)/ruby:$(hdrdir)/ruby
> 
> The correct paths for Windows need to be like the arch_hdrdir. When I
> change the above snippet into:
> 
> #### Start of system configuration section. ####
> 
> srcdir = C:/Source/git/thin/ext/thin_parser
> topdir = C:/Ruby/include/ruby-1.9.1
> hdrdir = C:/Ruby/include/ruby-1.9.1
> arch_hdrdir = C:/Ruby/include/ruby-1.9.1/$(arch)
> VPATH = $(srcdir):$(arch_hdrdir)/ruby:$(hdrdir)/ruby
> 
> The make works without any problem. So as long as a GEM relies on Make
> instead of rake, I'm able to manually compile and install these gems.
> However with rake, i'm unable to make these changes, because the the
> file is regenerated on every call and I cannot alter these paths.
> 
> I'd like to know if this behavior is intended, or is actually a bug
> inside the code that generates the paths on a Windows machine?
> 

As far as I can see, these paths are intended to work with the MSYS
environment of the MinGW project (MSYS provides an unix-like shell for
Windows). MSYS maps drive letters to paths under the root directory, i.e.:

C: -> /c
D: -> /d
C:\WINDOWS -> /c/WINDOWS
etc.

Btw. this behviour is inherited from Cygwin.

If you try to compile from the MSYS shell, it may work for you.

Vale,
Marvin
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.11 (GNU/Linux)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/

iQEcBAEBAgAGBQJNymhMAAoJELh1XLHFkqha7tEH/0jhVa55QCT+2SwZlk/oVU9K
lx9J6O1Glj/THuIS3INVqhaUDPB81/dn5gyiqd7gNKH3b/4GZluFBvlmnSpMV75W
os5e+aPZxjSh+AQJbM5hVO+tojo7Y16njjYCfPUyLiX7COgj9UJBIL8hdLUnVOkD
mzt/4ppDeKK7+hH0szxbsbFa50kI655So0ietFtfR3EQIbV47H7UO6eY7tkeskj4
gtmFuWxysMX9NOMQPiO6oK9EQFk5R/LAH8ti4jwlt0XHCSlEdUwOBkLf2+xoQdeo
aeml5dPJmYkGDpTNMhmo+RpCYarQDTfqvvcLZPgwpARoFBlxr7lJKL0eR2lxnZk=
=Qh7x
-----END PGP SIGNATURE-----