summaryrefslogtreecommitdiff
path: root/lib/rake/win32.rb
diff options
context:
space:
mode:
authornobu <nobu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2009-10-02 19:07:55 +0000
committernobu <nobu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2009-10-02 19:07:55 +0000
commit719b0f8e3037e1033726b6487d7b0d9fc1412e7d (patch)
treec5a08c8c9abae9b7f0514f680f56553a7a03656a /lib/rake/win32.rb
parenta0f667c33e24928374d494c9c33d0082355785e1 (diff)
* lib/rake: updated to rake code to rake-0.8.7 source code base.
* lib/rake/loaders/makefile.rb (Rake::MakefileLoader#process_line): respace dependencies too. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@25199 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'lib/rake/win32.rb')
-rw-r--r--lib/rake/win32.rb18
1 files changed, 15 insertions, 3 deletions
diff --git a/lib/rake/win32.rb b/lib/rake/win32.rb
index 96f66d6957c..0ab31c28221 100644
--- a/lib/rake/win32.rb
+++ b/lib/rake/win32.rb
@@ -5,9 +5,10 @@ module Rake
module Win32
class << self
# True if running on a windows system.
- def windows?
- # assume other DOSish systems are extinct.
- File::ALT_SEPARATOR == '\\'
+ if File::ALT_SEPARATOR == '\\' # assume other DOSish systems are extinct.
+ def windows?; true end
+ else
+ def windows?; false end
end
end
@@ -29,6 +30,17 @@ module Rake
end
File.expand_path('Rake', win32_shared_path)
end
+
+ # Normalize a win32 path so that the slashes are all forward slashes.
+ def normalize(path)
+ path.tr('\\', '/')
+ end
end if windows?
end
+
+ if Win32.windows?
+ def standard_system_dir
+ Win32.win32_system_dir
+ end
+ end
end