File tree 1 file changed +14
-7
lines changed 1 file changed +14
-7
lines changed Original file line number Diff line number Diff line change @@ -430,18 +430,25 @@ impl Library {
430
430
}
431
431
"-l" => {
432
432
self . libs . push ( val. to_string ( ) ) ;
433
- if statik && !is_system ( val, & dirs) {
434
- let meta = format ! ( "rustc-link-lib=static={}" , val) ;
435
- config. print_metadata ( & meta) ;
436
- } else {
437
- let meta = format ! ( "rustc-link-lib={}" , val) ;
438
- config. print_metadata ( & meta) ;
439
- }
440
433
}
441
434
_ => { }
442
435
}
443
436
}
444
437
438
+ for val in & self . libs {
439
+ if statik {
440
+ if is_system ( val, & dirs) {
441
+ panic ! ( "The library \" {}\" is a system library, \
442
+ which means it can't be linked statically!", val) ;
443
+ }
444
+ let meta = format ! ( "rustc-link-lib=static={}" , val) ;
445
+ config. print_metadata ( & meta) ;
446
+ } else {
447
+ let meta = format ! ( "rustc-link-lib={}" , val) ;
448
+ config. print_metadata ( & meta) ;
449
+ }
450
+ }
451
+
445
452
let mut iter = output. trim_right ( ) . split ( ' ' ) ;
446
453
while let Some ( part) = iter. next ( ) {
447
454
if part != "-framework" {
You can’t perform that action at this time.
0 commit comments