about summary refs log tree commit homepage
diff options
context:
space:
mode:
-rw-r--r--Rakefile32
1 files changed, 17 insertions, 15 deletions
diff --git a/Rakefile b/Rakefile
index f699c1b..6c4678f 100644
--- a/Rakefile
+++ b/Rakefile
@@ -44,6 +44,23 @@ Echoe.new("mongrel") do |p|
   
 end
 
+#### Ragel builder
+
+task :ragel do
+  Dir.chdir "ext/http11" do
+    target = "http11_parser.c"
+    File.unlink target if File.exist? target
+    sh "ragel http11_parser.rl | rlgen-cd -G2 -o #{target}"
+    raise "Failed to build C source" unless File.exist? target
+  end
+  Dir.chdir "ext/http11_java" do
+    target = "org/jruby/mongrel/Http11Parser.java"
+    File.unlink target if File.exist? target
+    sh "ragel -J http11_parser.rl | rlgen-java -o #{target}"
+    raise "Failed to build Java source" unless File.exist? target
+  end
+end
+
 #### A hack around RubyGems and Echoe for pre-compiled extensions.
 
 def move_extensions
@@ -164,21 +181,6 @@ task :gem_source => [:package_all] do
   rm "SVN_LOG"  
 end
 
-task :ragel do
-  Dir.chdir "ext/http11" do
-    target = "http11_parser.c"
-    File.unlink target if File.exist? target
-    sh "ragel http11_parser.rl | rlgen-cd -G2 -o #{target}"
-    raise "Failed to build C source" unless File.exist? target
-  end
-  Dir.chdir "ext/http11_java" do
-    target = "org/jruby/mongrel/Http11Parser.java"
-    File.unlink target if File.exist? target
-    sh "ragel -J http11_parser.rl | rlgen-java -o #{target}"
-    raise "Failed to build Java source" unless File.exist? target
-  end
-end
-
 task :site_webgen do
   sh "pushd site; webgen; ruby atom.rb > output/feed.atom; rsync -azv output/* rubyforge.org:/var/www/gforge-projects/mongrel/; popd"
 end