Module: Lmkplz::External

Defined in:
lib/lmkplz/metal.rb

Class Method Summary collapse

Class Method Details

.debug_pathObject



19
20
21
# File 'lib/lmkplz/metal.rb', line 19

def self.debug_path
  "ext/kkttyl/target/debug/libkkttyl.#{FFI::Platform::LIBSUFFIX}"
end

.pathObject



3
4
5
6
7
8
9
10
11
12
13
# File 'lib/lmkplz/metal.rb', line 3

def self.path
  path =
    if defined?($USE_DEBUG_KKTTYL) && $USE_DEBUG_KKTTYL
      warn "🐝  Using debug build of kkttyl"
      debug_path
    else
      release_path
    end

  File.expand_path(path, File.join(__dir__, "../.."))
end

.release_pathObject



15
16
17
# File 'lib/lmkplz/metal.rb', line 15

def self.release_path
  "ext/kkttyl/target/release/libkkttyl.#{FFI::Platform::LIBSUFFIX}"
end