hotspot/src/share/tools/ProjectCreator/Util.java
changeset 8303 81a0b8663748
parent 7397 5b173b4ca846
child 8860 98a7ff20acf0
--- a/hotspot/src/share/tools/ProjectCreator/Util.java	Thu Feb 10 12:55:56 2011 +0100
+++ b/hotspot/src/share/tools/ProjectCreator/Util.java	Thu Feb 10 13:03:22 2011 +0100
@@ -1,5 +1,5 @@
 /*
- * Copyright (c) 2005, 2010, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2005, 2011, Oracle and/or its affiliates. All rights reserved.
  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
  *
  * This code is free software; you can redistribute it and/or modify it
@@ -47,7 +47,7 @@
         return sb.toString();
     }
 
-     static String join(String padder, String v[]) {
+    static String join(String padder, String v[]) {
         StringBuffer sb = new StringBuffer();
 
         for (int i=0; i<v.length; i++) {
@@ -80,9 +80,16 @@
 
 
     static String normalize(String file) {
-        return file.replace('\\', '/');
+        file = file.replace('\\', '/');
+        if (file.length() > 2) {
+            if (file.charAt(1) == ':' && file.charAt(2) == '/') {
+                // convert drive letter to uppercase
+                String drive = file.substring(0, 1).toUpperCase();
+                return drive + file.substring(1);
+            }
+        }
+        return file;
     }
 
     static String sep = File.separator;
-    static String os = "Win32"; //System.getProperty("os.name");
 }