From: Lars Christensen Date: 2001-08-16T19:10:01+09:00 Subject: [ruby-talk:19881] Values written to rbconfig.rb by mkconfig.rb aren't properly quoted. On solaris, the variable ECHO_C will be added to rbconfig.rb with the value "\c", which in unparsable by Ruby (becomes control + "). This patch to mkconfig.rb should fix it: --- mkconfig.rb 2001/05/31 04:40:37 1.15 +++ mkconfig.rb 2001/08/16 09:25:03 @@ -39,7 +39,7 @@ next if $install_name and /^RUBY_INSTALL_NAME$/ =~ name next if $so_name and /^RUBY_SO_NAME$/ =~ name v = " CONFIG[\"" + name + "\"] = " + - val.sub(/^\s*(.*)\s*$/, '"\1"').gsub(/\$\{?(\w+)\}?/) { + val.sub(/\\/,'\\\\\\\\').sub(/^\s*(.*)\s*$/, '"\1"').gsub(/\$\{?(\w+)\}?/) { "$(#{$1})" } + "\n" if fast[name] I sense the need for a generic way to write objects in a ruby parseable way? String#inspect could have been used in this case, but it does not guarantee that parsing the output will result in an equivalent object. -- Lars Christensen, larsch@cs.auc.dk