From: Jake Farrell Date: Fri, 23 Sep 2011 17:24:00 +0000 (+0000) Subject: Thrift-1355: Running make in lib/rb doesn't build the native extensions X-Git-Tag: 0.8.0~74 X-Git-Url: https://source.supwisdom.com/gerrit/gitweb?a=commitdiff_plain;h=52092377395d2c8d763b7c0642efc4ce4eb5f130;p=common%2Fthrift.git Thrift-1355: Running make in lib/rb doesn't build the native extensions Client: rb Patch: jfarrell Builds extension prior to running spec calls to resolve test deps. git-svn-id: https://svn.apache.org/repos/asf/thrift/trunk@1174896 13f79535-47bb-0310-9956-ffa450edef68 --- diff --git a/lib/rb/Rakefile b/lib/rb/Rakefile index 780d6520..944134ab 100644 --- a/lib/rb/Rakefile +++ b/lib/rb/Rakefile @@ -25,7 +25,7 @@ require 'spec/rake/spectask' THRIFT = '../../compiler/cpp/thrift' task :default => [:gem] -task :spec => [:'gen-rb', :realspec] +task :spec => [:'gen-rb', :build_ext, :realspec] Spec::Rake::SpecTask.new(:realspec) do |t| t.spec_files = FileList['spec/**/*_spec.rb'] @@ -59,7 +59,7 @@ namespace :'gen-rb' do end desc "Build the native library" -task :build_ext => :spec do +task :build_ext => :'gen-rb' do Dir::chdir(File::dirname('ext/extconf.rb')) do unless sh "ruby #{File::basename('ext/extconf.rb')}" $stderr.puts "Failed to run extconf"