From 6d62a7de86369e046e6f6b221153d867df11e74c Mon Sep 17 00:00:00 2001 From: Eric Wong Date: Thu, 3 Jun 2010 17:15:18 -0700 Subject: [PATCH] depend on Isolate ~> 2.0.2 for development It's useful given all the Gems we support but don't have hard installation dependencies on. --- GNUmakefile | 5 ++--- Rakefile | 21 +++++---------------- rainbows.gemspec | 1 + t/GNUmakefile | 1 + 4 files changed, 9 insertions(+), 19 deletions(-) diff --git a/GNUmakefile b/GNUmakefile index 1125e69..4c4e783 100644 --- a/GNUmakefile +++ b/GNUmakefile @@ -3,7 +3,6 @@ all:: RUBY = ruby RAKE = rake GIT_URL = git://git.bogomips.org/rainbows.git -ISOLATE_CONFIG = config/isolate.rb GIT-VERSION-FILE: .FORCE-GIT-VERSION-FILE @./GIT-VERSION-GEN @@ -18,8 +17,8 @@ endif # rake takes forever to start isolate: tmp/isolate/ruby-$(RUBY_VERSION)/.isolate -tmp/isolate/ruby-$(RUBY_VERSION)/.isolate: $(ISOLATE_CONFIG) - ISOLATE_CONFIG=$(ISOLATE_CONFIG) $(RAKE) isolate +tmp/isolate/ruby-$(RUBY_VERSION)/.isolate: config/isolate.rb + $(RAKE) isolate > $@ base_bins := rainbows diff --git a/Rakefile b/Rakefile index 9cb9156..4f038c4 100644 --- a/Rakefile +++ b/Rakefile @@ -187,20 +187,9 @@ end desc 'isolate gems for development' task :isolate do require 'isolate' - require 'rbconfig' - - Isolate.now! :file => ENV['ISOLATE_CONFIG'], :system => false - - # for Ruby 1.8 isolate uses "1.8" instead of "1.8.7" for paths, - # but we'll still try to support 1.8.6 for now even though isolate - # does not. - if Gem.ruby_engine == "ruby" && - RbConfig::CONFIG["ruby_version"] != RUBY_VERSION - require 'fileutils' - Dir.chdir('tmp/isolate') do - FileUtils.rm_rf("ruby-#{RUBY_VERSION}") - File.symlink "ruby-#{RbConfig::CONFIG["ruby_version"]}", - "ruby-#{RUBY_VERSION}" - end - end + + Isolate.now!( + :system => false, + :multiruby => false, + :path => "tmp/isolate/ruby-#{RUBY_VERSION}") end diff --git a/rainbows.gemspec b/rainbows.gemspec index 57447a7..3327d05 100644 --- a/rainbows.gemspec +++ b/rainbows.gemspec @@ -44,6 +44,7 @@ Gem::Specification.new do |s| # The HTTP parser in Unicorn <= 0.97.0 was vulnerable to a remote DoS # when exposed directly to untrusted clients. s.add_dependency(%q, [">= 0.97.1", "< 2.0.0"]) + s.add_development_dependency(%q, "~> 2.0.2") # Unicorn already depends on Rack # s.add_dependency(%q) diff --git a/t/GNUmakefile b/t/GNUmakefile index 66c4681..81484a7 100644 --- a/t/GNUmakefile +++ b/t/GNUmakefile @@ -100,6 +100,7 @@ $(deps): { echo >&2 "E '$(dep_bin)' not found in PATH=$(PATH)"; exit 1; } @mv $@.$(pid) $@ dep: $(deps) + $(MAKE) -C .. isolate $(MODEL_T): export model = $(firstword $(subst ., ,$@)) $(MODEL_T): script = $(subst $(model).,,$@) -- 2.11.4.GIT