Commit db76ea7
authored
order limits.h before stdlib.h to workaround for glibc _FORTIFY_SOURCE (#1184)
`limits.h` must be included before `stdlib.h` when building with glibc
and having `_FORTIFY_SOURCE` set to a non-zero value.
When building with `_FORTIFY_SOURCE`, `realpath()` is inlined, and its
definition depends on whether `limits.h` has been included or not
(clearly, this is a terrible idea in terms of interacting with Clang
modules and should probably be fixed upstream). If the definition
differs from the one in SwiftGlibc, then _TestingInternals will not
build.1 parent 3440898 commit db76ea7
1 file changed
+6
-4
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
29 | 29 | | |
30 | 30 | | |
31 | 31 | | |
| 32 | + | |
| 33 | + | |
| 34 | + | |
| 35 | + | |
| 36 | + | |
| 37 | + | |
32 | 38 | | |
33 | 39 | | |
34 | 40 | | |
| |||
97 | 103 | | |
98 | 104 | | |
99 | 105 | | |
100 | | - | |
101 | | - | |
102 | | - | |
103 | | - | |
104 | 106 | | |
105 | 107 | | |
106 | 108 | | |
| |||
0 commit comments