Mercurial > hg > graal-jvmci-8
comparison src/share/tools/MakeDeps/Util.java @ 1408:0ba67bb5392c
added c1x build directory, added MSVC Win64 project support
author | lstadler |
---|---|
date | Wed, 12 May 2010 15:01:05 +0200 |
parents | a61af66fc99e |
children | 2d26b0046e0d |
comparison
equal
deleted
inserted
replaced
1407:09e7826ecf01 | 1408:0ba67bb5392c |
---|---|
21 * have any questions. | 21 * have any questions. |
22 * | 22 * |
23 */ | 23 */ |
24 | 24 |
25 import java.util.*; | 25 import java.util.*; |
26 import java.util.Map.Entry; | |
26 import java.io.File; | 27 import java.io.File; |
27 | 28 |
28 public class Util { | 29 public class Util { |
29 static String join(String padder, Vector v) { | 30 static String join(String padder, Vector v) { |
30 return join(padder, v, false); | 31 return join(padder, v, false); |
82 static String normalize(String file) { | 83 static String normalize(String file) { |
83 return file.replace('\\', '/'); | 84 return file.replace('\\', '/'); |
84 } | 85 } |
85 | 86 |
86 static String sep = File.separator; | 87 static String sep = File.separator; |
87 static String os = "Win32"; //System.getProperty("os.name"); | 88 |
89 private static String _os; | |
90 | |
91 static String os() { | |
92 if( _os==null) { | |
93 | |
94 for(Map.Entry<String, String> entry: System.getenv().entrySet()) | |
95 if("PLATFORM_ARCH_MODEL".equals(entry.getKey().toUpperCase())) { | |
96 String archModel = entry.getValue(); | |
97 if("x86_32".equals(archModel)) | |
98 _os = "Win32"; | |
99 else if("x86_64".equals(archModel)) | |
100 _os = "x64"; | |
101 else | |
102 throw new RuntimeException("Unsupported PLATFORM_ARCH_MODEL " + archModel); | |
103 return _os; | |
104 } | |
105 throw new RuntimeException("PLATFORM_ARCH_MODEL not specified"); | |
106 } | |
107 return _os; | |
108 } | |
88 } | 109 } |