linkage_checker: fix generic pathname calls.

This commit is contained in:
Mike McQuaid 2018-04-25 12:08:33 +01:00
parent 3454d6a961
commit 8035afcc36
2 changed files with 9 additions and 1 deletions

View File

@ -472,9 +472,17 @@ class Pathname
}
end
def binary_executable?
false
end
def mach_o_bundle?
false
end
def dylib?
false
end
end
require "extend/os/pathname"

View File

@ -66,7 +66,7 @@ class LinkageChecker
checked_dylibs = Set.new
@keg.find do |file|
next if file.symlink? || file.directory?
next unless file.dylib? || file.binary_executable? || file.mach_o_bundle?
next if !file.dylib? && !file.binary_executable? && !file.mach_o_bundle?
# weakly loaded dylibs may not actually exist on disk, so skip them
# when checking for broken linkage