File tree 2 files changed +10
-1
lines changed
2 files changed +10
-1
lines changed Original file line number Diff line number Diff line change @@ -2182,7 +2182,7 @@ impl Step for Assemble {
2182
2182
debug ! ( "copying codegen backends to sysroot" ) ;
2183
2183
copy_codegen_backends_to_sysroot ( builder, build_compiler, target_compiler) ;
2184
2184
2185
- if builder. config . lld_enabled {
2185
+ if builder. config . lld_enabled && !builder . is_system_llvm ( target_compiler . host ) {
2186
2186
builder. ensure ( crate :: core:: build_steps:: tool:: LldWrapper {
2187
2187
build_compiler,
2188
2188
target_compiler,
Original file line number Diff line number Diff line change @@ -2397,6 +2397,15 @@ impl Config {
2397
2397
) ;
2398
2398
}
2399
2399
2400
+ if config
2401
+ . target_config
2402
+ . get ( & config. build )
2403
+ . is_some_and ( |config| config. llvm_config . is_some ( ) )
2404
+ && config. lld_enabled
2405
+ {
2406
+ panic ! ( "Cannot enable LLD when using external llvm-config." ) ;
2407
+ }
2408
+
2400
2409
let default_std_features = BTreeSet :: from ( [ String :: from ( "panic-unwind" ) ] ) ;
2401
2410
config. rust_std_features = std_features. unwrap_or ( default_std_features) ;
2402
2411
You can’t perform that action at this time.
0 commit comments