mozilla/rust — pull request #13017 by alexcrichton (2014-03-19 15:53:09+00:00)
Title: rustc: Prevent false positives in crate loading

Previously, any library of the pattern `lib--.so` was
>considered a candidate (rightly so) for loading a crate. Sets are generated for
each unique ``, and then from these sets a candidate is selected. If a set
contained more than one element, then it immediately generated an error saying
that multiple copies of the same dylib were found.

This is incorrect because each candidate needs to be validated to actually
contain a rust library (valid metadata). This commit alters the logic to filter
each set of candidates for a hash to only libraries which are actually rust
libraries. This means that if multiple false positives are found with the right
name pattern, they're all ignored.

Closes #13010