From 4f166ce0211fcb47d6d7598e2521389bda67d74f Mon Sep 17 00:00:00 2001 From: Maxim Belkin Date: Wed, 22 Aug 2018 21:25:00 -0500 Subject: [PATCH] formula_cellar_checks: .dylib and .framework are macOS-specific --- Library/Homebrew/extend/os/mac/formula_cellar_checks.rb | 5 +++++ Library/Homebrew/formula_cellar_checks.rb | 2 +- 2 files changed, 6 insertions(+), 1 deletion(-) diff --git a/Library/Homebrew/extend/os/mac/formula_cellar_checks.rb b/Library/Homebrew/extend/os/mac/formula_cellar_checks.rb index eb16b93d81..5919816064 100644 --- a/Library/Homebrew/extend/os/mac/formula_cellar_checks.rb +++ b/Library/Homebrew/extend/os/mac/formula_cellar_checks.rb @@ -94,4 +94,9 @@ module FormulaCellarChecks problem_if_output(check_python_framework_links(formula.lib)) check_linkage end + + def valid_library_extension?(filename) + macos_lib_extensions = %w[.dylib .framework] + generic_valid_library_extension?(filename) || macos_lib_extensions.include?(filename.extname) + end end diff --git a/Library/Homebrew/formula_cellar_checks.rb b/Library/Homebrew/formula_cellar_checks.rb index 9d1633be9a..2902ed303b 100644 --- a/Library/Homebrew/formula_cellar_checks.rb +++ b/Library/Homebrew/formula_cellar_checks.rb @@ -56,7 +56,7 @@ module FormulaCellarChecks EOS end - VALID_LIBRARY_EXTENSIONS = %w[.a .dylib .framework .jnilib .la .o .so .jar .prl .pm .sh].freeze + VALID_LIBRARY_EXTENSIONS = %w[.a .jnilib .la .o .so .jar .prl .pm .sh].freeze def valid_library_extension?(filename) VALID_LIBRARY_EXTENSIONS.include? filename.extname