1 # -*- encoding: binary -*-
2 manifest = File.exist?('.manifest') ?
3 IO.readlines('.manifest').map!(&:chomp!) : `git ls-files`.split("\n")
5 # don't bother with tests that fork, not worth our time to get working
6 # with `gem check -t` ... (of course we care for them when testing with
7 # GNU make when they can run in parallel)
8 test_files = manifest.grep(%r{\Atest/unit/test_.*\.rb\z}).map do |f|
9 File.readlines(f).grep(/\bfork\b/).empty? ? f : nil
12 Gem::Specification.new do |s|
14 s.version = (ENV['VERSION'] || '6.0.0').dup
15 s.authors = ['unicorn hackers']
16 s.summary = 'Rack HTTP server for fast clients and Unix'
17 s.description = File.read('README').split("\n\n")[1]
18 s.email = %q{unicorn-public@yhbt.net}
19 s.executables = %w(unicorn unicorn_rails)
20 s.extensions = %w(ext/unicorn_http/extconf.rb)
21 s.extra_rdoc_files = IO.readlines('.document').map!(&:chomp!).keep_if do |f|
25 s.homepage = 'https://yhbt.net/unicorn/'
26 s.test_files = test_files
28 # 1.9.3 is the minumum supported version. We don't specify
29 # a maximum version to make it easier to test pre-releases,
30 # but we do warn users if they install unicorn on an untested
31 # version in extconf.rb
32 s.required_ruby_version = ">= 1.9.3"
34 # We do not have a hard dependency on rack, it's possible to load
35 # things which respond to #call. HTTP status lines in responses
36 # won't have descriptive text, only the numeric status.
37 s.add_development_dependency(%q<rack>)
39 s.add_dependency(%q<kgio>, '~> 2.6')
40 s.add_dependency(%q<raindrops>, '~> 0.7')
42 s.add_development_dependency('test-unit', '~> 3.0')
44 # Note: To avoid ambiguity, we intentionally avoid the SPDX-compatible
45 # 'Ruby' here since Ruby 1.9.3 switched to BSD-2-Clause, but we
46 # inherited our license from Mongrel when Ruby was at 1.8.
47 # We cannot automatically switch licenses when Ruby changes.
48 s.licenses = ['GPL-2.0+', 'Ruby-1.8']