Commit 1bb2fe6
Fix Alpine/musl test-suite blockers: busybox diff, aarch64 wchar_t
- runtests.sh used diff --strip-trailing-cr unconditionally; busybox
diff (Alpine) lacks that option, so every .expect comparison errored
and counted as a mismatch. Probe for the option once.
- c2mir's builtin aarch64 stddef.h declared 'typedef int wchar_t;', but
wchar_t is unsigned int in AAPCS64 (and caarch64.h already says
MIR_WCHAR_MIN 0). glibc never notices because its headers trust the
compiler's stddef.h, but musl's bits/alltypes.h redeclares wchar_t
per-arch ('typedef unsigned wchar_t;'), making every program that
includes both fail with 'repeated declaration wchar_t' - this broke
the c2m bootstrap on Alpine aarch64. Keep int on Apple (signed
there), and fix the __WCHAR_MAX__/__WCHAR_MIN__ predefines on Linux
to match gcc (4294967295u / 0u).
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>1 parent d867ffb commit 1bb2fe6
3 files changed
Lines changed: 18 additions & 4 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
34 | 34 | | |
35 | 35 | | |
36 | 36 | | |
| 37 | + | |
| 38 | + | |
| 39 | + | |
| 40 | + | |
| 41 | + | |
| 42 | + | |
| 43 | + | |
37 | 44 | | |
38 | 45 | | |
39 | 46 | | |
| |||
57 | 64 | | |
58 | 65 | | |
59 | 66 | | |
60 | | - | |
| 67 | + | |
61 | 68 | | |
62 | 69 | | |
63 | 70 | | |
64 | 71 | | |
65 | 72 | | |
66 | 73 | | |
67 | | - | |
| 74 | + | |
68 | 75 | | |
69 | 76 | | |
70 | 77 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
52 | 52 | | |
53 | 53 | | |
54 | 54 | | |
55 | | - | |
| 55 | + | |
| 56 | + | |
| 57 | + | |
56 | 58 | | |
57 | 59 | | |
58 | | - | |
59 | 60 | | |
| 61 | + | |
60 | 62 | | |
61 | 63 | | |
62 | 64 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
10 | 10 | | |
11 | 11 | | |
12 | 12 | | |
| 13 | + | |
13 | 14 | | |
| 15 | + | |
| 16 | + | |
| 17 | + | |
| 18 | + | |
14 | 19 | | |
15 | 20 | | |
16 | 21 | | |
| |||
0 commit comments