summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorusa <usa@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2007-12-29 21:28:53 +0000
committerusa <usa@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2007-12-29 21:28:53 +0000
commit757b27d07d18ac2f50ace6b1c7787bae704e326f (patch)
tree121d3a6bd8b4158b02154dd059be1e1d5c95cbbf
parent817e4eaaf9d24589358ec9db64b4c33a29cc8ed6 (diff)
downloadruby-757b27d07d18ac2f50ace6b1c7787bae704e326f.tar.gz
ruby-757b27d07d18ac2f50ace6b1c7787bae704e326f.tar.xz
ruby-757b27d07d18ac2f50ace6b1c7787bae704e326f.zip
* lib/mkmf.rb (depend_rules): need to convert `/' to `\' for windows
native commands. git-svn-id: http://svn.ruby-lang.org/repos/ruby/trunk@14789 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
-rw-r--r--ChangeLog5
-rw-r--r--lib/mkmf.rb4
2 files changed, 9 insertions, 0 deletions
diff --git a/ChangeLog b/ChangeLog
index 952630fa7..4715c35ed 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,8 @@
+Sun Dec 30 06:27:38 2007 NAKAMURA Usaku <usa@ruby-lang.org>
+
+ * lib/mkmf.rb (depend_rules): need to convert `/' to `\' for windows
+ native commands.
+
Sun Dec 30 01:43:56 2007 Nobuyoshi Nakada <nobu@ruby-lang.org>
* enc/Makefile.in (DLDFLAGS): like as extensions. [ruby-core:14567]
diff --git a/lib/mkmf.rb b/lib/mkmf.rb
index 055ed226e..d99209e2d 100644
--- a/lib/mkmf.rb
+++ b/lib/mkmf.rb
@@ -1308,6 +1308,10 @@ def depend_rules(depend)
line.gsub!(/\.o\b/, ".#{$OBJEXT}")
line.gsub!(/\$\((?:hdr|top)dir\)\/config.h/, $config_h) if $config_h
line.gsub!(%r"\$\(hdrdir\)/(?!ruby(?![^:;/\s]))(?=[-\w]+\.h)", '\&ruby/')
+ if $nmake && /\A\s*\$\(RM|COPY\)/ =~ line
+ line.gsub!(%r"[-\w\./]{2,}"){$&.tr("/", "\\")}
+ line.gsub!(/(\$\((?!RM|COPY)[^:)]+)(?=\))/, '\1:/=\\')
+ end
if /(?:^|[^\\])(?:\\\\)*\\$/ =~ line
(cont ||= []) << line
next