Sha256: b4e811aa3c1b0c3d8c8ed80b4976125b9dadb6b7983caf5b2f44daef52855d53

Contents?: true

Size: 752 Bytes

Versions: 2

Compression:

Stored size: 752 Bytes

Contents

require 'rbconfig'
require 'shellwords'

module Libv8; end

module Libv8::Node
  module Paths
    module_function

    def include_paths
      [Shellwords.escape(File.join(vendored_source_path, 'include'))]
    end

    def object_paths
      [Shellwords.escape(File.join(vendored_source_path,
                                   platform,
                                   'libv8',
                                   'obj',
                                   "libv8_monolith.#{config['LIBEXT']}"))]
    end

    def platform
      Gem::Platform.local.to_s.gsub(/-darwin-?\d+/, '-darwin')
    end

    def config
      RbConfig::MAKEFILE_CONFIG
    end

    def vendored_source_path
      File.expand_path('../../vendor/v8', __dir__)
    end
  end
end

Version data entries

2 entries across 2 versions & 1 rubygems

Version Path
libv8-node-16.10.0.0-arm64-darwin ext/libv8-node/paths.rb
libv8-node-16.10.0.0-x86_64-darwin ext/libv8-node/paths.rb