Module: Lxi::LibChecker

Extended by:
FFI::Library
Defined in:
lib/lxi/methods.rb

Class Method Summary collapse

Class Method Details

.installed?(lib_paths = []) ⇒ Boolean

Returns:

  • (Boolean)


15
16
17
18
19
20
21
22
23
# File 'lib/lxi/methods.rb', line 15

def self.installed?(lib_paths = [])
  lib_paths.each do |path|
    ffi_lib path
    return true
  rescue LoadError
    next
  end
  false
end