don't copy symbols from dylibs with -Zdylib-lto

This commit is contained in:
Rémy Rakic 2022-12-16 20:37:53 +00:00
parent 63b3bac77c
commit d2f4a9ca25

View File

@ -253,7 +253,7 @@ pub fn each_linked_rlib(
};
for &cnum in crates {
match fmts.get(cnum.as_usize() - 1) {
Some(&Linkage::NotLinked | &Linkage::IncludedFromDylib) => continue,
Some(&Linkage::NotLinked | &Linkage::Dynamic | &Linkage::IncludedFromDylib) => continue,
Some(_) => {}
None => return Err(errors::LinkRlibError::MissingFormat),
}