mirror of
https://github.com/ruby/ruby.git
synced 2025-08-23 04:55:21 +02:00
10 lines
300 B
Ruby
10 lines
300 B
Ruby
require 'mkmf'
|
|
|
|
if RUBY_ENGINE == 'truffleruby'
|
|
# The pure-Ruby generator is faster on TruffleRuby, so skip compiling the generator extension
|
|
File.write('Makefile', dummy_makefile("").join)
|
|
else
|
|
append_cflags("-std=c99")
|
|
$defs << "-DJSON_GENERATOR"
|
|
create_makefile 'json/ext/generator'
|
|
end
|