Sha256: bb16d0aad1e194c74e0e34a692ff309e78bf65cae6501afefda5fc4d535c9b6d

Contents?: true

Size: 772 Bytes

Versions: 163

Compression:

Stored size: 772 Bytes

Contents

# frozen_string_literal: false
require 'mkmf'

have_func("rb_enc_raise", "ruby.h")
have_func("rb_enc_interned_str", "ruby.h")

# checking if String#-@ (str_uminus) dedupes... '
begin
  a = -(%w(t e s t).join)
  b = -(%w(t e s t).join)
  if a.equal?(b)
    $CFLAGS << ' -DSTR_UMINUS_DEDUPE=1 '
  else
    $CFLAGS << ' -DSTR_UMINUS_DEDUPE=0 '
  end
rescue NoMethodError
  $CFLAGS << ' -DSTR_UMINUS_DEDUPE=0 '
end

# checking if String#-@ (str_uminus) directly interns frozen strings... '
begin
  s = rand.to_s.freeze
  if (-s).equal?(s) && (-s.dup).equal?(s)
    $CFLAGS << ' -DSTR_UMINUS_DEDUPE_FROZEN=1 '
  else
    $CFLAGS << ' -DSTR_UMINUS_DEDUPE_FROZEN=0 '
  end
rescue NoMethodError
  $CFLAGS << ' -DSTR_UMINUS_DEDUPE_FROZEN=0 '
end

create_makefile 'json/ext/parser'

Version data entries

163 entries across 161 versions & 21 rubygems

Version Path
harbr-0.1.68 vendor/bundle/ruby/3.2.0/gems/json-2.7.0/ext/json/ext/parser/extconf.rb
harbr-0.1.67 vendor/bundle/ruby/3.2.0/gems/json-2.7.0/ext/json/ext/parser/extconf.rb
harbr-0.1.66 vendor/bundle/ruby/3.2.0/gems/json-2.7.0/ext/json/ext/parser/extconf.rb
harbr-0.1.65 vendor/bundle/ruby/3.2.0/gems/json-2.7.0/ext/json/ext/parser/extconf.rb
harbr-0.1.64 vendor/bundle/ruby/3.2.0/gems/json-2.7.0/ext/json/ext/parser/extconf.rb
harbr-0.1.63 vendor/bundle/ruby/3.2.0/gems/json-2.7.0/ext/json/ext/parser/extconf.rb
harbr-0.1.62 vendor/bundle/ruby/3.2.0/gems/json-2.7.0/ext/json/ext/parser/extconf.rb
harbr-0.1.61 vendor/bundle/ruby/3.2.0/gems/json-2.7.0/ext/json/ext/parser/extconf.rb
harbr-0.1.60 vendor/bundle/ruby/3.2.0/gems/json-2.7.0/ext/json/ext/parser/extconf.rb
harbr-0.1.59 vendor/bundle/ruby/3.2.0/gems/json-2.7.0/ext/json/ext/parser/extconf.rb
harbr-0.1.58 vendor/bundle/ruby/3.2.0/gems/json-2.7.0/ext/json/ext/parser/extconf.rb
harbr-0.1.57 vendor/bundle/ruby/3.2.0/gems/json-2.7.0/ext/json/ext/parser/extconf.rb
harbr-0.1.56 vendor/bundle/ruby/3.2.0/gems/json-2.7.0/ext/json/ext/parser/extconf.rb
harbr-0.1.55 vendor/bundle/ruby/3.2.0/gems/json-2.7.0/ext/json/ext/parser/extconf.rb
harbr-0.1.54 vendor/bundle/ruby/3.2.0/gems/json-2.7.0/ext/json/ext/parser/extconf.rb
harbr-0.1.53 vendor/bundle/ruby/3.2.0/gems/json-2.7.0/ext/json/ext/parser/extconf.rb
harbr-0.1.52 vendor/bundle/ruby/3.2.0/gems/json-2.7.0/ext/json/ext/parser/extconf.rb
harbr-0.1.50 vendor/bundle/ruby/3.2.0/gems/json-2.7.0/ext/json/ext/parser/extconf.rb
harbr-0.1.49 vendor/bundle/ruby/3.2.0/gems/json-2.7.0/ext/json/ext/parser/extconf.rb
harbr-0.1.48 vendor/bundle/ruby/3.2.0/gems/json-2.7.0/ext/json/ext/parser/extconf.rb