Sha256: e94b5dd8b1692fa03d4098814c7a5cbed6f3cd25a308c163a7f873152b976c43
Contents?: true
Size: 1.07 KB
Versions: 6
Compression:
Stored size: 1.07 KB
Contents
module TransmitterWrapper extend FFI::Library arch = case FFI::Platform::ARCH when 'x86_64' 'X64' when 'x86' 'X86' when 'arm' 'ARM' when 'aarch64' 'ARM64' else raise "Unsupported architecture: #{FFI::Platform::ARCH}" end if OS.linux? ffi_lib File.expand_path("../../../Binaries/Native/Linux/#{arch}/libJavonetRubyRuntimeNative.so", __FILE__) elsif OS.mac? ffi_lib File.expand_path("../../../Binaries/Native/MacOs/#{arch}/libJavonetRubyRuntimeNative.dylib", __FILE__) else RubyInstaller::Runtime.add_dll_directory(File.expand_path("../../../Binaries/Native/Windows/#{arch}/", __FILE__)) ffi_lib File.expand_path("../../../Binaries/Native/Windows/#{arch}/JavonetRubyRuntimeNative.dll", __FILE__) end attach_function :SendCommand, [:pointer, :int], :int attach_function :ReadResponse, [:pointer, :int], :int attach_function :Activate, [:pointer], :int attach_function :GetNativeError, [], :string attach_function :SetConfigSource, [:pointer], :int end
Version data entries
6 entries across 3 versions & 1 rubygems