1 |
Tl;DR |
2 |
----- |
3 |
|
4 |
libffi-3.4 entered ::gento without KEYWORDS today. |
5 |
After some testing it will be promoted into ~arch. |
6 |
|
7 |
libffi has two modes: |
8 |
1. USE=-exec-static-trampoline: old (default, safe) |
9 |
2. USE=exec-static-trampoline: new (cool, might expose latent bugs) |
10 |
|
11 |
+toralf@ (CC): |
12 |
Toralf, can we set a tinderbox run for [1.] |
13 |
>=dev-libs/libffi-3.4[-exec-static-trampoline] |
14 |
case? |
15 |
|
16 |
[2.] would also be nice: |
17 |
>=dev-libs/libffi-3.4[exec-static-trampoline] |
18 |
My worry is that it will generate a lot of collateral |
19 |
breakage (at least some percentage of dev-haskell/*). |
20 |
|
21 |
Tracker: https://bugs.gentoo.org/801109 |
22 |
Known examples: https://wiki.gentoo.org/index.php?title=Project:Toolchain#libffi-3.4 |
23 |
|
24 |
More help |
25 |
--------- |
26 |
|
27 |
If you happen to maintain a Gentoo package that uses libffi |
28 |
you can try libffi-3.4 early to see how it behaves. |
29 |
|
30 |
- Try [1.] on packages you maintain. |
31 |
- If you are brave try [2.] as well but be ready to recover |
32 |
your system! A few packages are already known to be affected: |
33 |
https://wiki.gentoo.org/index.php?title=Project:Toolchain#libffi-3.4 |
34 |
|
35 |
Add new bugs you found as blockers to the libffi-3.4 tracker: |
36 |
https://bugs.gentoo.org/801109 |
37 |
|
38 |
More words |
39 |
---------- |
40 |
|
41 |
In this release most probably impactful change is a trampoline |
42 |
code handling change. |
43 |
|
44 |
Before 3.4 libffi generated all code at runtime in a single |
45 |
executable chunk of executable memory. |
46 |
|
47 |
Since 3.4 libffi uses does not use runtime code generation and |
48 |
uses statically defined trampoline in a very clever way: |
49 |
https://sourceware.org/pipermail/libffi-discuss/2021/002579.html |
50 |
|
51 |
This should not be a problem for most applications, but two |
52 |
are already known to fail: |
53 |
|
54 |
- ghc: https://gitlab.haskell.org/ghc/ghc/-/issues/20051 |
55 |
- gobject-introspection: https://gitlab.gnome.org/GNOME/gobject-introspection/-/merge_requests/283 |
56 |
|
57 |
The symptoms are SIGSEGVs and erratic behaviour. |
58 |
|
59 |
To workaround widespread breakage libffi-3.4 provides a fallback mode |
60 |
that reuses libffi-3.3 style trampoline layout via USE=-exec-static-trampoline. |
61 |
|
62 |
Also note that libffi-3.4 also changes SONAME from libffi.so.7 |
63 |
to libffi.so.8. It will rebuild a few packages as a result. |
64 |
It's a good time to check for missing rebuild slot operator in |
65 |
depends. |
66 |
|
67 |
If you broke your system with USE=exec-static-trampoline try to |
68 |
recover with USE=-exec-static-trampoline first. It should avoid |
69 |
rebuilding revdeps back to .so.7. |
70 |
|
71 |
Debugging help |
72 |
-------------- |
73 |
|
74 |
If you suspect your package is affected then CC toolchain@ |
75 |
to the relevant bug and we'll try to sort it out together. |
76 |
|
77 |
Have fun! |
78 |
|
79 |
-- |
80 |
|
81 |
Sergei |