Sha256: b2226ba731f35a31e3d3a749dac4e7aa3554e6ee0dff7a8ba1fec0f47500d7cd
Contents?: true
Size: 643 Bytes
Versions: 5
Compression:
Stored size: 643 Bytes
Contents
# frozen_string_literal: true require "ffi-libarchive-binary/version" require "pathname" module LibarchiveBinary class Error < StandardError; end LIBRARY_PATH = Pathname.new(File.join(__dir__, "ffi-libarchive-binary")) end module Archive module C def self.ffi_lib(*args) prefixed = args.map do |names| filenames = names.is_a?(Array) ? names : [names] with_path = filenames.map(&:to_s).map do |filename| LibarchiveBinary::LIBRARY_PATH.join(FFI.map_library_name(filename)).to_s end with_path + filenames end super(*prefixed) end end end require "ffi-libarchive"
Version data entries
5 entries across 5 versions & 1 rubygems