File tree Expand file tree Collapse file tree 2 files changed +12
-29
lines changed
src/librustc_codegen_llvm Expand file tree Collapse file tree 2 files changed +12
-29
lines changed Load Diff This file was deleted.
Original file line number Diff line number Diff line change @@ -72,9 +72,8 @@ use rustc_codegen_utils::codegen_backend::CodegenBackend;
72
72
mod diagnostics;
73
73
74
74
mod back {
75
- mod archive;
75
+ pub mod archive;
76
76
pub mod bytecode;
77
- pub mod link;
78
77
pub mod lto;
79
78
pub mod write;
80
79
}
@@ -328,8 +327,17 @@ impl CodegenBackend for LlvmCodegenBackend {
328
327
// This should produce either a finished executable or library.
329
328
sess. profiler ( |p| p. start_activity ( ProfileCategory :: Linking , "link_crate" ) ) ;
330
329
time ( sess, "linking" , || {
331
- back:: link:: link_binary ( sess, & codegen_results,
332
- outputs, & codegen_results. crate_name . as_str ( ) ) ;
330
+ use rustc_codegen_ssa:: back:: link:: link_binary;
331
+ use crate :: back:: archive:: LlvmArchiveBuilder ;
332
+
333
+ let target_cpu = crate :: llvm_util:: target_cpu ( sess) ;
334
+ link_binary :: < LlvmArchiveBuilder < ' _ > > (
335
+ sess,
336
+ & codegen_results,
337
+ outputs,
338
+ & codegen_results. crate_name . as_str ( ) ,
339
+ target_cpu,
340
+ ) ;
333
341
} ) ;
334
342
sess. profiler ( |p| p. end_activity ( ProfileCategory :: Linking , "link_crate" ) ) ;
335
343
You can’t perform that action at this time.
0 commit comments