mirror of
https://codeberg.org/ziglang/zig.git
synced 2025-12-07 14:24:43 +00:00
std: add more missing windows libraries when running tests
This commit is contained in:
parent
ee9ef86d89
commit
871d29b1a4
1 changed files with 10 additions and 4 deletions
|
|
@ -1039,11 +1039,17 @@ pub fn addModuleTests(b: *std.Build, options: ModuleTestOptions) *Step {
|
||||||
},
|
},
|
||||||
});
|
});
|
||||||
compile_c.addIncludePath("lib"); // for zig.h
|
compile_c.addIncludePath("lib"); // for zig.h
|
||||||
if (test_target.link_libc == false and test_target.target.getOsTag() == .windows) {
|
if (test_target.target.getOsTag() == .windows) {
|
||||||
|
if (test_target.link_libc == false) {
|
||||||
compile_c.subsystem = .Console;
|
compile_c.subsystem = .Console;
|
||||||
compile_c.linkSystemLibrary("kernel32");
|
compile_c.linkSystemLibrary("kernel32");
|
||||||
compile_c.linkSystemLibrary("ntdll");
|
compile_c.linkSystemLibrary("ntdll");
|
||||||
|
}
|
||||||
if (mem.eql(u8, options.name, "std")) {
|
if (mem.eql(u8, options.name, "std")) {
|
||||||
|
if (test_target.link_libc == false) {
|
||||||
|
compile_c.linkSystemLibrary("shell32");
|
||||||
|
compile_c.linkSystemLibrary("advapi32");
|
||||||
|
}
|
||||||
compile_c.linkSystemLibrary("crypt32");
|
compile_c.linkSystemLibrary("crypt32");
|
||||||
compile_c.linkSystemLibrary("ws2_32");
|
compile_c.linkSystemLibrary("ws2_32");
|
||||||
compile_c.linkSystemLibrary("ole32");
|
compile_c.linkSystemLibrary("ole32");
|
||||||
|
|
|
||||||
Loading…
Add table
Reference in a new issue