authorgravatar for andrew@ziglang.orgAndrew Kelley <andrew@ziglang.org> 2025-10-27 19:47:20-07:00
committergravatar for andrew@ziglang.orgAndrew Kelley <andrew@ziglang.org> 2025-10-29 06:20:51-07:00
log030ddc79528d41571b8329252c5f853d477a0f7b
tree1d5a3f3af3041698322f3ea8a1bf177856cc3d4b
parent135ec79f50ff36d48563be126c3e49793b04f302

update standalone tests for ws2_32 dependency


2 files changed, 2 insertions(+), 1 deletions(-)

test/standalone/test_obj_link_run/build.zig+1
...@@ -11,6 +11,7 @@ pub fn build(b: *std.Build) void {...@@ -11,6 +11,7 @@ pub fn build(b: *std.Build) void {
11 if (is_windows) {11 if (is_windows) {
12 test_obj.linkSystemLibrary("ntdll");12 test_obj.linkSystemLibrary("ntdll");
13 test_obj.linkSystemLibrary("kernel32");13 test_obj.linkSystemLibrary("kernel32");
14 test_obj.linkSystemLibrary("ws2_32");
14 }15 }
1516
16 const test_exe_mod = b.createModule(.{17 const test_exe_mod = b.createModule(.{
test/standalone/windows_spawn/main.zig+1-1
...@@ -224,7 +224,7 @@ fn renameExe(dir: std.fs.Dir, old_sub_path: []const u8, new_sub_path: []const u8...@@ -224,7 +224,7 @@ fn renameExe(dir: std.fs.Dir, old_sub_path: []const u8, new_sub_path: []const u8
224 error.AccessDenied => {224 error.AccessDenied => {
225 if (attempt == 13) return error.AccessDenied;225 if (attempt == 13) return error.AccessDenied;
226 // give the kernel a chance to finish closing the executable handle226 // give the kernel a chance to finish closing the executable handle
227 std.os.windows.kernel32.Sleep(@as(u32, 1) << attempt >> 1);227 _ = std.os.windows.kernel32.SleepEx(@as(u32, 1) << attempt >> 1, std.os.windows.FALSE);
228 attempt += 1;228 attempt += 1;
229 continue;229 continue;
230 },230 },