Sha256: db846c315a1174ab5e5785cea9cac8caabde09442d877892da6234abb980c265

Contents?: true

Size: 861 Bytes

Versions: 41

Compression:

Stored size: 861 Bytes

Contents

require "rbconfig"

begin
  require 'ffi'
rescue LoadError
  raise ChildProcess::MissingFFIError
end

module ChildProcess
  module Windows
    module Lib
      extend FFI::Library

      def self.msvcrt_name
        host_part = RbConfig::CONFIG['host_os'].split("_")[1]
        manifest  = File.join(RbConfig::CONFIG['bindir'], 'ruby.exe.manifest')

        if host_part && host_part.to_i > 80 && File.exists?(manifest)
          "msvcr#{host_part}"
        else
          "msvcrt"
        end
      end

      ffi_lib "kernel32", msvcrt_name
      ffi_convention :stdcall


    end # Library
  end # Windows
end # ChildProcess

require "childprocess/windows/lib"
require "childprocess/windows/structs"
require "childprocess/windows/handle"
require "childprocess/windows/io"
require "childprocess/windows/process_builder"
require "childprocess/windows/process"

Version data entries

41 entries across 29 versions & 7 rubygems

Version Path
tdiary-5.2.4 vendor/bundle/ruby/3.1.0/gems/childprocess-4.1.0/lib/childprocess/windows.rb
tdiary-5.2.3 vendor/bundle/ruby/3.1.0/gems/childprocess-4.1.0/lib/childprocess/windows.rb
tdiary-5.2.2 vendor/bundle/ruby/3.1.0/gems/childprocess-4.1.0/lib/childprocess/windows.rb
tdiary-5.2.1 vendor/bundle/ruby/3.1.0/gems/childprocess-4.1.0/lib/childprocess/windows.rb
phillipug-foodie-0.1.0 .vendor/ruby/3.0.0/gems/childprocess-4.1.0/lib/childprocess/windows.rb
vagrant-unbundled-2.2.19.0 vendor/bundle/ruby/3.0.0/gems/childprocess-4.1.0/lib/childprocess/windows.rb
tdiary-5.2.0 vendor/bundle/ruby/2.7.0/gems/childprocess-3.0.0/lib/childprocess/windows.rb
tdiary-5.2.0 vendor/bundle/ruby/3.0.0/gems/childprocess-4.1.0/lib/childprocess/windows.rb
date_n_time_picker_activeadmin-0.1.2 vendor/bundle/ruby/2.6.0/gems/childprocess-4.1.0/lib/childprocess/windows.rb
date_n_time_picker_activeadmin-0.1.1 vendor/bundle/ruby/2.6.0/gems/childprocess-4.1.0/lib/childprocess/windows.rb
vagrant-unbundled-2.2.18.0 vendor/bundle/ruby/3.0.0/gems/childprocess-4.1.0/lib/childprocess/windows.rb
tdiary-5.1.7 vendor/bundle/ruby/2.7.0/gems/childprocess-3.0.0/lib/childprocess/windows.rb
tdiary-5.1.7 vendor/bundle/ruby/3.0.0/gems/childprocess-3.0.0/lib/childprocess/windows.rb
childprocess-4.1.0 lib/childprocess/windows.rb
tdiary-5.1.6 vendor/bundle/ruby/3.0.0/gems/childprocess-3.0.0/lib/childprocess/windows.rb
tdiary-5.1.6 vendor/bundle/ruby/2.7.0/gems/tdiary-5.1.5/vendor/bundle/ruby/3.0.0/gems/tdiary-5.1.4/vendor/bundle/ruby/2.7.0/gems/childprocess-3.0.0/lib/childprocess/windows.rb
tdiary-5.1.6 vendor/bundle/ruby/2.7.0/gems/tdiary-5.1.5/vendor/bundle/ruby/3.0.0/gems/childprocess-3.0.0/lib/childprocess/windows.rb
tdiary-5.1.6 vendor/bundle/ruby/2.7.0/gems/tdiary-5.1.5/vendor/bundle/ruby/2.7.0/gems/childprocess-3.0.0/lib/childprocess/windows.rb
tdiary-5.1.6 vendor/bundle/ruby/2.7.0/gems/childprocess-3.0.0/lib/childprocess/windows.rb
vagrant-unbundled-2.2.16.0 vendor/bundle/ruby/2.7.0/gems/childprocess-4.0.0/lib/childprocess/windows.rb