Simplify re-definition of targets
This commit is contained in:
parent
542694728c
commit
fa635db8a1
@ -1588,11 +1588,9 @@ class Formula
|
||||
# universal binaries in a {Formula}'s {Keg}.
|
||||
sig { params(targets: T.nilable(T.any(Pathname, String))).void }
|
||||
def deuniversalize_machos(*targets)
|
||||
if targets.blank?
|
||||
targets = any_installed_keg.mach_o_files.select do |file|
|
||||
targets ||= any_installed_keg.mach_o_files.select do |file|
|
||||
file.arch == :universal && file.archs.include?(Hardware::CPU.arch)
|
||||
end
|
||||
end
|
||||
|
||||
targets.each { |t| extract_macho_slice_from(Pathname.new(t), Hardware::CPU.arch) }
|
||||
end
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user