Signed-off-by: James Le Cuirot <chewi@gentoo.org>
---
eclass/cargo.eclass | 9 +++++++++
1 file changed, 9 insertions(+)
diff --git a/eclass/cargo.eclass b/eclass/cargo.eclass
index 44d3f7ee31f59..9f0bffee0e048 100644
--- a/eclass/cargo.eclass
+++ b/eclass/cargo.eclass
@@ -532,7 +532,16 @@ cargo_src_configure() {
# host and target host respectively. Ensure these are set consistently between
# Cargo invocations, otherwise rebuilds will occur.
cargo_env() {
+ # Shadow flag variables so that filtering below remains local.
+ local flag
+ for flag in $(all-flag-vars); do
+ local -x "${flag}=${!flag}"
+ done
+
+ # Rust extensions are incompatible with C/C++ LTO compiler see e.g.
+ # https://bugs.gentoo.org/910220
filter-lto
+
Sysop: | Keyop |
---|---|
Location: | Huddersfield, West Yorkshire, UK |
Users: | 407 |
Nodes: | 16 (2 / 14) |
Uptime: | 15:43:51 |
Calls: | 8,555 |
Calls today: | 7 |
Files: | 13,219 |
Messages: | 5,925,786 |