From: Bryan Duxbury Date: Wed, 17 Nov 2010 22:47:06 +0000 (+0000) Subject: THRIFT-979. rb: ruby bindings used to work on jruby X-Git-Tag: 0.6.0~32 X-Git-Url: https://source.supwisdom.com/gerrit/gitweb?a=commitdiff_plain;h=c3affb3940d1f479e5a68d6a6a5e32cb5d19a87e;p=common%2Fthrift.git THRIFT-979. rb: ruby bindings used to work on jruby Make a dummy makefile so that JRuby doesn't complain. Patch: Jeff Hodges git-svn-id: https://svn.apache.org/repos/asf/thrift/trunk@1036267 13f79535-47bb-0310-9956-ffa450edef68 --- diff --git a/lib/rb/ext/extconf.rb b/lib/rb/ext/extconf.rb index 07558b8a..36dac9b7 100644 --- a/lib/rb/ext/extconf.rb +++ b/lib/rb/ext/extconf.rb @@ -17,10 +17,14 @@ # under the License. # -require 'mkmf' +if defined?(RUBY_ENGINE) && RUBY_ENGINE =~ /jruby/ + File.open('Makefile', 'w'){|f| f.puts "all:\n\ninstall:\n" } +else + require 'mkmf' -$CFLAGS = "-g -O2 -Wall -Werror" + $CFLAGS = "-g -O2 -Wall -Werror" -have_func("strlcpy", "string.h") + have_func("strlcpy", "string.h") -create_makefile 'thrift_native' + create_makefile 'thrift_native' +end