Merge pull request #9322 from MikeMcQuaid/linkage-fixes
linkage: correctly detect missing kegs.
This commit is contained in:
commit
d7f03bc2dd
@ -193,7 +193,9 @@ class Keg
|
||||
# @param path if this is a file in a keg, returns the containing {Keg} object.
|
||||
def self.for(path)
|
||||
original_path = path
|
||||
if original_path.exist? && (path = original_path.realpath)
|
||||
raise Errno::ENOENT, original_path.to_s unless original_path.exist?
|
||||
|
||||
if (path = original_path.realpath)
|
||||
until path.root?
|
||||
return Keg.new(path) if path.parent.parent == HOMEBREW_CELLAR.realpath
|
||||
|
||||
|
||||
@ -68,16 +68,6 @@ class LinkageChecker
|
||||
display_items "Broken dependencies", @broken_deps, puts_output: puts_output
|
||||
display_items "Unwanted system libraries", @unwanted_system_dylibs, puts_output: puts_output
|
||||
display_items "Conflicting libraries", @version_conflict_deps, puts_output: puts_output
|
||||
|
||||
if @broken_dylibs.empty?
|
||||
puts "No broken library linkage detected"
|
||||
elsif unexpected_broken_dylibs.empty?
|
||||
puts "No unexpected broken library linkage detected."
|
||||
else
|
||||
puts "Unexpected missing library linkage detected"
|
||||
end
|
||||
|
||||
puts "Unexpected non-missing linkage detected" if unexpected_present_dylibs.present?
|
||||
end
|
||||
|
||||
sig { returns(T::Boolean) }
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user