@@ -473,13 +473,24 @@ fn check_for_buggy_ld_version(sess: &Session,
473
473
program_name, flavor, crate_type) ;
474
474
475
475
match crate_type {
476
- config:: CrateType :: Dylib |
477
- config:: CrateType :: ProcMacro => ( ) ,
476
+ // This is the one case that we fire on, because it is the one place we
477
+ // know of where using the output in a "supported" fashion (*) can
478
+ // trigger the bug in old GNU ld versions.
479
+ //
480
+ // (*) Of course this raises the question of how much support do we give
481
+ // Rust dylibs in the first place
482
+ config:: CrateType :: Dylib => ( ) ,
478
483
479
484
// FIXME: should we include CrateType::Cdylib in the warning? It is not
480
485
// clear why we haven't seen it there.
481
486
config:: CrateType :: Cdylib => return ,
482
487
488
+ // We deliberately do not include CrateType::ProcMacro in the warning,
489
+ // as it would cause too many false-positives (and ot actually observe
490
+ // the known bugs in that context, you would have to be using the
491
+ // geneated dylib in an unsupported fashion anyway).
492
+ config:: CrateType :: ProcMacro => return ,
493
+
483
494
// Static objects won't run into this (unless they load a dynamic
484
495
// object, which this heuristic is not attempting to detect).
485
496
config:: CrateType :: Executable |
0 commit comments