Sha256: 8b46bff9d8e81f32725f1fabd52e0de264507c057a79c12c6738f7c7dbbc2324

Contents?: true

Size: 1.44 KB

Versions: 3

Compression:

Stored size: 1.44 KB

Contents

require "ffi"

if RUBY_PLATFORM =~ /mswin$|mingw|win32\-|\-win32/
  binary_path = File.expand_path("../lib", __dir__)
  # 64-bit builds of Windows use "x64-mingw" as RUBY_PLATFORM
  binary_path += "64" if RUBY_PLATFORM =~ /^x64-/

  begin
    # Make DLLs available as shown here:
    # https://github.com/oneclick/rubyinstaller2/wiki/For-gem-developers
    require "ruby_installer"
    RubyInstaller::Runtime.add_dll_directory(binary_path)
  rescue LoadError
    # Add this gem to the PATH on Windows so that bundled DLLs can be found.
    # When running through Ocra on Windows, we need to be careful to preserve the ENV["PATH"]
    # encoding (see #385).
    path_encoding = ENV["PATH"].encoding
    ENV["PATH"] = "#{binary_path.encode(path_encoding)};#{ENV["PATH"]}"
  end

  # Add the correct lib directory for the current version of Ruby (major.minor).
  $LOAD_PATH.prepend File.join(binary_path, RUBY_VERSION[/^\d+.\d+/])
end

module Gosu
end

require_relative "gosu/ffi"
require_relative "gosu/constants"

require_relative "gosu/numeric"

# Individual classes need to be loaded after defining GosuFFI.check_last_error.

require_relative "gosu/gosu"

require_relative "gosu/channel"
require_relative "gosu/color"
require_relative "gosu/font"
require_relative "gosu/gl_tex_info"
require_relative "gosu/image"
require_relative "gosu/sample"
require_relative "gosu/song"
require_relative "gosu/text_input"
require_relative "gosu/window"

require_relative "gosu/compat"

Version data entries

3 entries across 3 versions & 1 rubygems

Version Path
gosu-2.0.0.pre8 lib/gosu.rb
gosu-2.0.0.pre7 lib/gosu.rb
gosu-2.0.0.pre6 lib/gosu.rb