summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authortduehr <tduehr@users.noreply.github.com>2021-06-02 09:55:30 -0500
committerGitHub <noreply@github.com>2021-06-02 09:55:30 -0500
commit82e20928319e499b2e60679205733cb5f088c363 (patch)
tree78ca09bb983a637c39a3025f91036ec3b627e5b5
parent513aef49803774ed1a4201f2ae4b51b63955db8b (diff)
parent5c0a3279adfa402544f0714bfd6bd12382defebb (diff)
downloadffi-82e20928319e499b2e60679205733cb5f088c363.tar.gz
Merge pull request #882 from OleMchls/patch-1
dynlib support for homebrew 3 on Apple Silicon M1
-rw-r--r--lib/ffi/library.rb2
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/ffi/library.rb b/lib/ffi/library.rb
index c6f9654..1f8602b 100644
--- a/lib/ffi/library.rb
+++ b/lib/ffi/library.rb
@@ -126,7 +126,7 @@ module FFI
else
# TODO better library lookup logic
unless libname.start_with?("/") || FFI::Platform.windows?
- path = ['/usr/lib/','/usr/local/lib/','/opt/local/lib/'].find do |pth|
+ path = ['/usr/lib/','/usr/local/lib/','/opt/local/lib/', '/opt/homebrew/lib/'].find do |pth|
File.exist?(pth + libname)
end
if path