1 |
we do it in src_compile to avoid excessive flag stripping in projects |
2 |
using cargo.eclass just to fetch crates. |
3 |
|
4 |
Closes: https://bugs.gentoo.org/893658 |
5 |
Signed-off-by: Georgy Yakovlev <gyakovlev@g.o> |
6 |
--- |
7 |
eclass/cargo.eclass | 3 ++- |
8 |
1 file changed, 2 insertions(+), 1 deletion(-) |
9 |
|
10 |
diff --git a/eclass/cargo.eclass b/eclass/cargo.eclass |
11 |
index 00b8078f80ea..27ccee1295b3 100644 |
12 |
--- a/eclass/cargo.eclass |
13 |
+++ b/eclass/cargo.eclass |
14 |
@@ -49,7 +49,7 @@ case "${EAPI:-0}" in |
15 |
;; |
16 |
esac |
17 |
|
18 |
-inherit multiprocessing toolchain-funcs |
19 |
+inherit flag-o-matic multiprocessing toolchain-funcs |
20 |
|
21 |
if [[ ! ${CARGO_OPTIONAL} ]]; then |
22 |
BDEPEND="${RUST_DEPEND}" |
23 |
@@ -525,6 +525,7 @@ cargo_src_compile() { |
24 |
[[ ${_CARGO_GEN_CONFIG_HAS_RUN} ]] || \ |
25 |
die "FATAL: please call cargo_gen_config before using ${FUNCNAME}" |
26 |
|
27 |
+ filter-lto |
28 |
tc-export AR CC CXX PKG_CONFIG |
29 |
|
30 |
set -- cargo build --profile gentoo ${ECARGO_ARGS[@]} "$@" |
31 |
-- |
32 |
2.39.1 |