Skip to content

Commit c643245

Browse files
committed
Fix stat.h check on Alpine.
1 parent 9cd7538 commit c643245

2 files changed

Lines changed: 5 additions & 2 deletions

File tree

Tools/configure/conf_platform.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -586,7 +586,7 @@ def check_structs(v):
586586
"struct statx.stx_dio_read_offset_align",
587587
"struct statx.stx_atomic_write_unit_max_opt",
588588
):
589-
pyconf.check_member(m, includes=["linux/stat.h"])
589+
pyconf.check_member(m)
590590

591591
# altzone in time.h
592592
pyconf.checking("for time.h that defines altzone")

Tools/configure/pyconf.py

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2551,7 +2551,10 @@ def check_member(member: str, includes: list[str] | None = None) -> bool:
25512551
if len(parts) != 2:
25522552
return False
25532553
struct_name, field = parts
2554-
inc_lines = "".join(f"#include <{h}>\n" for h in (includes or []))
2554+
if includes is not None:
2555+
inc_lines = "".join(f"#include <{h}>\n" for h in includes)
2556+
else:
2557+
inc_lines = _ac_includes_default()
25552558
src = (
25562559
f"{inc_lines}\n"
25572560
f"int main(void) {{\n"

0 commit comments

Comments
 (0)