Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Make sure upstream object files are added to staticlibs when compiling
with ThinLTO and cross-lang-lto. Normally, when compiling with whole-crate-graph ThinLTO, we expect rustc's LTO step to "uplift" upstream object files/LLVM modules to the current set of compilation artifacts. Therefore the staticlib creation code skips this uplifting. However, when compiling with "cross-language LTO" (i.e. defer LTO to the actual linker), the LTO step in rustc is not performed, so we have to take care of copying upstream object files during archive creation (like we already do when compiling without any LTO).
- Loading branch information