1 |
Closes: https://bugs.gentoo.org/646076 |
2 |
Signed-off-by: Sam James <sam@g.o> |
3 |
--- |
4 |
eclass/flag-o-matic.eclass | 5 +++++ |
5 |
1 file changed, 5 insertions(+) |
6 |
|
7 |
diff --git a/eclass/flag-o-matic.eclass b/eclass/flag-o-matic.eclass |
8 |
index 37577209281a1..d6590a2e52dfd 100644 |
9 |
--- a/eclass/flag-o-matic.eclass |
10 |
+++ b/eclass/flag-o-matic.eclass |
11 |
@@ -55,6 +55,11 @@ _setup-allowed-flags() { |
12 |
'-fstack-check*' -fno-stack-check |
13 |
-fbounds-check -fbounds-checking |
14 |
-fno-PIE -fno-pie -nopie -no-pie |
15 |
+ # Spectre mitigations, bug #646076 |
16 |
+ '-mindirect-branch=*' |
17 |
+ -mindirect-branch-register |
18 |
+ '-mfunction-return=*' |
19 |
+ -mretpoline |
20 |
|
21 |
# Misc |
22 |
-fno-unit-at-a-time -fno-strict-overflow |
23 |
-- |
24 |
2.34.1 |