Commit d269d7d
authored
Fix undefined symbol error in version script (#55363)
lld 17 and above by default error if symbols listed in the version
script are undefined. Julia has a few of these, as some symbols are
defined conditionally in Julia (e.g. based on OS), others perhaps have
been removed from Julia and other seem to be defined in other libraries.
Further the version script is used in linking three times, each time
linking together different objects and so having different symbols
defined.
Adding `-Wl,--undefined-version` is not a great solution as passing that
to ld < 2.40 errors and there doesn't seem to be a great way to check if
a linker supports this flag.
I don't know how to get around these errors for symbols like
`_IO_stdin_used` which Julia doesn't define and it seems to matter
whether or not they are exported, see
https://libc-alpha.sourceware.narkive.com/SevIQmU3/io-stdin-used-stripped-by-version-scripts.
So I've converted all undefined symbols into wildcards to work around
the error.
Fixes #50414, fixes #54533 and replaces #55319.
---------
Co-authored-by: Zentrik <Zentrik@users.noreply.github.com>1 parent 10f294b commit d269d7d
2 files changed
+20
-20
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1470 | 1470 | | |
1471 | 1471 | | |
1472 | 1472 | | |
1473 | | - | |
| 1473 | + | |
1474 | 1474 | | |
1475 | 1475 | | |
1476 | 1476 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
2 | 2 | | |
3 | 3 | | |
4 | 4 | | |
5 | | - | |
| 5 | + | |
6 | 6 | | |
7 | 7 | | |
8 | 8 | | |
9 | 9 | | |
10 | 10 | | |
11 | 11 | | |
12 | 12 | | |
13 | | - | |
| 13 | + | |
14 | 14 | | |
15 | | - | |
16 | | - | |
17 | | - | |
18 | | - | |
19 | | - | |
20 | | - | |
21 | | - | |
| 15 | + | |
| 16 | + | |
| 17 | + | |
| 18 | + | |
| 19 | + | |
| 20 | + | |
| 21 | + | |
22 | 22 | | |
23 | 23 | | |
24 | | - | |
| 24 | + | |
25 | 25 | | |
26 | | - | |
27 | | - | |
28 | | - | |
29 | | - | |
30 | | - | |
31 | | - | |
| 26 | + | |
| 27 | + | |
| 28 | + | |
| 29 | + | |
| 30 | + | |
| 31 | + | |
32 | 32 | | |
33 | 33 | | |
34 | 34 | | |
35 | | - | |
| 35 | + | |
36 | 36 | | |
37 | 37 | | |
38 | | - | |
39 | | - | |
| 38 | + | |
| 39 | + | |
40 | 40 | | |
41 | 41 | | |
42 | 42 | | |
| |||
0 commit comments