1
0
Fork 0
mirror of https://github.com/ruby/ruby.git synced 2022-11-09 12:17:21 -05:00

[ruby/fiddle] try bundled libffi by default

If no installed libffi found, use bundled libffi unless explicitly
`--disable-bundled-libffi` option is given.
This commit is contained in:
Nobuyoshi Nakada 2020-06-28 00:57:37 +09:00
parent f2bcdc7283
commit c405a8d37a
No known key found for this signature in database
GPG key ID: 7CD2805BFA3770C6
Notes: git 2020-06-28 02:03:18 +09:00

View file

@ -37,7 +37,7 @@ unless have_libffi
Dir.glob("#{$srcdir}/libffi-*/").each{|dir| FileUtils.rm_rf(dir)}
extlibs.run(["--cache=#{cache_dir}", ext_dir])
end
if bundle
if bundle != false
libffi_package_name = Dir.glob("#{$srcdir}/libffi-*/")
.map {|n| File.basename(n)}
.max_by {|n| n.scan(/\d+/).map(&:to_i)}