| ... | ... | @@ -9,6 +9,7 @@ const build_options = @import("build_options"); |
| 9 | 9 | const is_darwin = Target.current.isDarwin(); |
| 10 | 10 | const is_windows = Target.current.os.tag == .windows; |
| 11 | 11 | const is_gnu = Target.current.isGnu(); |
| 12 | const is_haiku = Target.current.os.tag == .haiku; |
| 12 | 13 | |
| 13 | 14 | const log = std.log.scoped(.libc_installation); |
| 14 | 15 | |
| ... | ... | @@ -279,8 +280,14 @@ pub const LibCInstallation = struct { |
| 279 | 280 | return error.CCompilerCannotFindHeaders; |
| 280 | 281 | } |
| 281 | 282 | |
| 282 | | const include_dir_example_file = "stdlib.h"; |
| 283 | | const sys_include_dir_example_file = if (is_windows) "sys\\types.h" else "sys/errno.h"; |
| 283 | const include_dir_example_file = if (is_haiku) "posix/stdlib.h" else "stdlib.h"; |
| 284 | const sys_include_dir_example_file = if (is_windows) |
| 285 | "sys\\types.h" |
| 286 | else if (is_haiku) |
| 287 | "posix/errno.h" |
| 288 | else |
| 289 | "sys/errno.h" |
| 290 | ; |
| 284 | 291 | |
| 285 | 292 | var path_i: usize = 0; |
| 286 | 293 | while (path_i < search_paths.items.len) : (path_i += 1) { |