| ... | ... | @@ -168,29 +168,22 @@ pub const LibCInstallation = struct { |
| 168 | 168 | var self: LibCInstallation = .{}; |
| 169 | 169 | |
| 170 | 170 | if (is_windows) { |
| 171 | | if (is_gnu) { |
| 172 | | var batch = Batch(FindError!void, 3, .auto_async).init(); |
| 173 | | batch.add(&async self.findNativeIncludeDirPosix(args)); |
| 174 | | batch.add(&async self.findNativeCrtDirPosix(args)); |
| 175 | | try batch.wait(); |
| 176 | | } else { |
| 177 | | var sdk: *ZigWindowsSDK = undefined; |
| 178 | | switch (zig_find_windows_sdk(&sdk)) { |
| 179 | | .None => { |
| 180 | | defer zig_free_windows_sdk(sdk); |
| 181 | | |
| 182 | | var batch = Batch(FindError!void, 5, .auto_async).init(); |
| 183 | | batch.add(&async self.findNativeMsvcIncludeDir(args, sdk)); |
| 184 | | batch.add(&async self.findNativeMsvcLibDir(args, sdk)); |
| 185 | | batch.add(&async self.findNativeKernel32LibDir(args, sdk)); |
| 186 | | batch.add(&async self.findNativeIncludeDirWindows(args, sdk)); |
| 187 | | batch.add(&async self.findNativeCrtDirWindows(args, sdk)); |
| 188 | | try batch.wait(); |
| 189 | | }, |
| 190 | | .OutOfMemory => return error.OutOfMemory, |
| 191 | | .NotFound => return error.WindowsSdkNotFound, |
| 192 | | .PathTooLong => return error.WindowsSdkNotFound, |
| 193 | | } |
| 171 | var sdk: *ZigWindowsSDK = undefined; |
| 172 | switch (zig_find_windows_sdk(&sdk)) { |
| 173 | .None => { |
| 174 | defer zig_free_windows_sdk(sdk); |
| 175 | |
| 176 | var batch = Batch(FindError!void, 5, .auto_async).init(); |
| 177 | batch.add(&async self.findNativeMsvcIncludeDir(args, sdk)); |
| 178 | batch.add(&async self.findNativeMsvcLibDir(args, sdk)); |
| 179 | batch.add(&async self.findNativeKernel32LibDir(args, sdk)); |
| 180 | batch.add(&async self.findNativeIncludeDirWindows(args, sdk)); |
| 181 | batch.add(&async self.findNativeCrtDirWindows(args, sdk)); |
| 182 | try batch.wait(); |
| 183 | }, |
| 184 | .OutOfMemory => return error.OutOfMemory, |
| 185 | .NotFound => return error.WindowsSdkNotFound, |
| 186 | .PathTooLong => return error.WindowsSdkNotFound, |
| 194 | 187 | } |
| 195 | 188 | } else { |
| 196 | 189 | try blk: { |