@@ -39,8 +39,10 @@ def scrub(b):
39
39
"freebsd" : ["bin/rustc" ],
40
40
}
41
41
42
- winnt_runtime_deps = ["libgcc_s_dw2-1.dll" ,
43
- "libstdc++-6.dll" ]
42
+ winnt_runtime_deps_32 = ["libgcc_s_dw2-1.dll" ,
43
+ "libstdc++-6.dll" ]
44
+ winnt_runtime_deps_64 = ["libgcc_s_seh-1.dll" ,
45
+ "libstdc++-6.dll" ]
44
46
45
47
def parse_line (n , line ):
46
48
global snapshotfile
@@ -146,10 +148,14 @@ def hash_file(x):
146
148
return scrub (h .hexdigest ())
147
149
148
150
# Returns a list of paths of Rust's system runtime dependencies
149
- def get_winnt_runtime_deps ():
151
+ def get_winnt_runtime_deps (platform ):
152
+ if platform == "winnt-x86_64" :
153
+ deps = winnt_runtime_deps_64
154
+ else :
155
+ deps = winnt_runtime_deps_32
150
156
runtime_deps = []
151
- path_dirs = os .environ ["PATH" ].split (';' )
152
- for name in winnt_runtime_deps :
157
+ path_dirs = os .environ ["PATH" ].split (os . pathsep )
158
+ for name in deps :
153
159
for dir in path_dirs :
154
160
matches = glob .glob (os .path .join (dir , name ))
155
161
if matches :
@@ -189,7 +195,7 @@ def in_tar_name(fn):
189
195
"Please make a clean build." % "\n " .join (matches ))
190
196
191
197
if kernel == "winnt" :
192
- for path in get_winnt_runtime_deps ():
198
+ for path in get_winnt_runtime_deps (platform ):
193
199
tar .add (path , "rust-stage0/bin/" + os .path .basename (path ))
194
200
tar .add (os .path .join (os .path .dirname (__file__ ), "third-party" ),
195
201
"rust-stage0/bin/third-party" )
0 commit comments