libstd-rs: embed bitcode for LTO

Fixes #294.
This commit is contained in:
Dan Callaghan
2021-02-05 11:39:44 +10:00
parent c72b2dda3a
commit b7eacc0996

View File

@@ -12,6 +12,8 @@ DEPENDS_append_libc-musl = " libunwind"
DEPENDS_remove_riscv32 = "libunwind"
DEPENDS_remove_riscv64 = "libunwind"
# Embed bitcode in order to allow compiling both with and without LTO
RUSTFLAGS += "-Cembed-bitcode=yes"
# Needed so cargo can find libbacktrace
RUSTFLAGS += "-L ${STAGING_LIBDIR} -C link-arg=-Wl,-soname,libstd.so"