5 Echoe.new("unicorn") do |p|
6 p.summary = "Rack HTTP server for Unix, fast clients and nothing else"
8 p.email = "normalperson@yhbt.net"
9 p.clean_pattern = ['ext/unicorn/http11/*.{bundle,so,o,obj,pdb,lib,def,exp}',
10 'lib/*.{bundle,so,o,obj,pdb,lib,def,exp}',
11 'ext/unicorn/http11/Makefile',
12 'pkg', 'lib/*.bundle', '*.gem',
13 'site/output', '.config', 'coverage',
14 'test_*.log', 'log', 'doc']
15 p.url = "http://unicorn.bogomips.org/"
16 p.ignore_pattern = /^(pkg|site|projects|doc|log)|CVS|\.log/
19 p.dependencies = [ 'rack' ]
21 p.extension_pattern = ["ext/**/extconf.rb"]
23 # Eric hasn't bothered to figure out running exec tests properly
24 # from Rake, but Eric prefers GNU make to Rake for tests anyways...
25 p.test_pattern = [ 'test/unit/test*.rb' ]
30 desc "Rebuild the Ragel sources"
32 Dir.chdir "ext/unicorn/http11" do
33 target = "http11_parser.c"
34 File.unlink target if File.exist? target
35 sh "ragel http11_parser.rl -C -G2 -o #{target}"
36 raise "Failed to build C source" unless File.exist? target