Re: [RubyInstaller] DevKit, pik, and spaces in path names

84 views
Skip to first unread message

Luis Lavena

unread,
May 21, 2013, 11:06:34 AM5/21/13
to rubyin...@googlegroups.com
Hello Charlie, and welcome.

On Mon, May 20, 2013 at 3:31 PM, Charlie Bosson <cebo...@gmail.com> wrote:
I found a topic similar to this in the forum from last year, but no update, so I thought I'd try a post.

By default, pik places new ruby vers in %USERPROFILE%, which of course expands to a path name with spaces in it, e.g. C:\Documents and Settings\...
No matter how I format the entries in the DevKit confg.yml, eventually the spaces will foil make, like so:

Updating json
Building native extensions.  This could take a while...
ERROR:  Error installing json:
        ERROR: Failed to build gem native extension.

        "C:/Documents and Settings/Charlie Bosson/.pik/rubies/Ruby-193-p392/bin/ruby.exe" extconf.rb

creating Makefile

make
generating generator-i386-mingw32.def
/bin/sh: C:/Documents: No such file or directory
make: *** [generator-i386-mingw32.def] Error 127

I tried all forms of quotes, escaping the characters, 8.3 names, env vars, what have you.
Can DevKit handle spaces in the path names, or should I delete my current Ruby installs and change pik to point to a location without spaces?

The problem with spaces is not an issue of DevKit (GCC) itself, but more of Ruby.

Ruby 1.8.x and 1.9.3 suffer from this on how mkmf (the tool that generates Makefiles) handle spaces.

This has been solved in Ruby 2.0, as a similar issue was raised to Ruby and fixed:


However, this work cannot be backported to Ruby 1.9.3 since the changes around mkmf were too big.

You can avoid issue of Pik installing into %USERPROFILE% by setting %PIK_HOME% in your environment.

For example, some folks have set %PIK_HOME% to C:\Rubies and set that in your user environment variables.

Of course, if you change your current installation, you will require to update DevKit configuration too, so don't forget to "ruby dk.rb install --force".

Hope that helps.
-- 
Luis Lavena
AREA 17
-
Perfection in design is achieved not when there is nothing more to add,
but rather when there is nothing more to take away.
Antoine de Saint-Exupéry
Reply all
Reply to author
Forward
0 new messages