Skip to content

Commit

Permalink
Clean up
Browse files Browse the repository at this point in the history
  • Loading branch information
sds committed Dec 20, 2023
1 parent c0778d0 commit e795a47
Show file tree
Hide file tree
Showing 7 changed files with 3 additions and 897 deletions.
29 changes: 0 additions & 29 deletions lib/childprocess/windows.rb
Original file line number Diff line number Diff line change
@@ -1,38 +1,9 @@
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"
91 changes: 0 additions & 91 deletions lib/childprocess/windows/handle.rb

This file was deleted.

Loading

0 comments on commit e795a47

Please sign in to comment.