Sha256: aad9da2efc14fb8dfa48b1a4fb29ca9586e2091a83b93976ed6a9d05762de74d

Contents?: true

Size: 1.16 KB

Versions: 21

Compression:

Stored size: 1.16 KB

Contents

# use rake-compiler for building the extension
require 'rake/extensiontask'

# NOTE: version used by cross compilation of Windows native extension
# It do not affect compilation under other operating systems
# The version indicated is the minimum DLL suggested for correct functionality
BINARY_VERSION = "3.7.9"
URL_VERSION    = "3070900"

# build sqlite3_native C extension
Rake::ExtensionTask.new('sqlite3_native', HOE.spec) do |ext|
  # where to locate the extension
  ext.ext_dir = 'ext/sqlite3'

  # where native extension will be copied (matches makefile)
  ext.lib_dir = "lib/sqlite3"

  # clean binary folders always
  CLEAN.include("#{ext.lib_dir}/?.?")

  # automatically add build options to avoid need of manual input
  if RUBY_PLATFORM =~ /mswin|mingw/ then
    # define target for extension (supporting fat binaries)
    RUBY_VERSION =~ /(\d+\.\d+)/
    ext.lib_dir = "lib/sqlite3/#{$1}"
    ext.config_options << "--enable-local"
  else
    ext.cross_compile = true
    ext.cross_platform = ['i386-mswin32-60', 'i386-mingw32']
    ext.cross_config_options << "--enable-local"
  end
end

# ensure things are compiled prior testing
task :test => [:compile]

# vim: syntax=ruby

Version data entries

21 entries across 21 versions & 2 rubygems

Version Path
challah-0.6.2 vendor/bundle/gems/sqlite3-1.3.5/tasks/native.rake
challah-0.6.1 vendor/bundle/gems/sqlite3-1.3.5/tasks/native.rake
challah-0.6.0 vendor/bundle/gems/sqlite3-1.3.5/tasks/native.rake
challah-0.5.4 vendor/bundle/gems/sqlite3-1.3.5/tasks/native.rake
challah-0.5.3 vendor/bundle/gems/sqlite3-1.3.5/tasks/native.rake
challah-0.5.2 vendor/bundle/gems/sqlite3-1.3.5/tasks/native.rake
challah-0.5.1 vendor/bundle/gems/sqlite3-1.3.5/tasks/native.rake
challah-0.5.0 vendor/bundle/gems/sqlite3-1.3.5/tasks/native.rake
challah-0.4.1 vendor/bundle/gems/sqlite3-1.3.5/tasks/native.rake
challah-0.4.0 vendor/bundle/gems/sqlite3-1.3.5/tasks/native.rake
challah-0.3.5 vendor/bundle/gems/sqlite3-1.3.5/tasks/native.rake
challah-0.3.4 vendor/bundle/gems/sqlite3-1.3.5/tasks/native.rake
challah-0.3.3 vendor/bundle/gems/sqlite3-1.3.5/tasks/native.rake
challah-0.3.2 vendor/bundle/gems/sqlite3-1.3.5/tasks/native.rake
challah-0.3.1 vendor/bundle/gems/sqlite3-1.3.5/tasks/native.rake
challah-0.3.0 vendor/bundle/gems/sqlite3-1.3.5/tasks/native.rake
challah-0.2.1 vendor/bundle/gems/sqlite3-1.3.5/tasks/native.rake
challah-0.2.0 vendor/bundle/gems/sqlite3-1.3.5/tasks/native.rake
sqlite3-1.3.5-x86-mswin32-60 tasks/native.rake
sqlite3-1.3.5-x86-mingw32 tasks/native.rake