Sha256: 46ede57aa87563a629904b1819f67ffc43554b47cbd37ad41ff8ee7251dcab46

Contents?: true

Size: 842 Bytes

Versions: 9

Compression:

Stored size: 842 Bytes

Contents

require 'rbconfig'
require 'mkmf'

if RbConfig::CONFIG['host_os'] =~ /darwin/ then
  $CFLAGS += " -DUSE_INSTANT_OSX=1 -Wall"
  $LDFLAGS += " -framework CoreServices"
elsif RbConfig::CONFIG['host_os'] =~ /win32/ or RbConfig::CONFIG['host_os'] =~ /mingw/ then
  $CFLAGS += " -DUSE_INSTANT_WINDOWS=1"
else
  if have_library("rt", "clock_gettime") then
    $CFLAGS += " -DUSE_INSTANT_CLOCK_GETTIME=1"
  elsif have_library("c", "clock_gettime") then
    $CFLAGS += " -DUSE_INSTANT_CLOCK_GETTIME=1"
  else
    raise NotImplementedError, <<-_
Unable to find the function 'clock_gettime' in either libc or librt.
Please file an issue at https://github.com/copiousfreetime/hitimes.
_
  end
end

# put in a different location if on windows so we can have fat binaries
subdir = RUBY_VERSION.gsub(/\.\d$/,'')
create_makefile("hitimes/#{subdir}/hitimes")

Version data entries

9 entries across 7 versions & 4 rubygems

Version Path
honeybadger-2.4.0 vendor/gems/ruby/1.9.1/gems/hitimes-1.2.2/ext/hitimes/c/extconf.rb
honeybadger-2.4.0 vendor/gems/ruby/2.2.0/gems/hitimes-1.2.2/ext/hitimes/c/extconf.rb
honeybadger-2.4.0 vendor/gems/ruby/2.1.0/gems/hitimes-1.2.2/ext/hitimes/c/extconf.rb
scoot-0.0.4 .bundle/gems/ruby/2.2.0/gems/hitimes-1.2.2/ext/hitimes/c/extconf.rb
vagrant-cloudstack-1.1.0 vendor/bundle/gems/hitimes-1.2.2/ext/hitimes/c/extconf.rb
hitimes-1.2.2-x86-mingw32 ext/hitimes/c/extconf.rb
hitimes-1.2.2-x86-mswin32-60 ext/hitimes/c/extconf.rb
hitimes-1.2.2-java ext/hitimes/c/extconf.rb
hitimes-1.2.2 ext/hitimes/c/extconf.rb