1 # Copyright 1999-2016 Gentoo Foundation
2 # Distributed under the terms of the GNU General Public License v2
6 USE_RUBY="ruby20 ruby21"
8 # Documentation task depends on sdoc which we currently don't have.
9 RUBY_FAKEGEM_TASK_DOC=""
10 RUBY_FAKEGEM_TASK_TEST="none"
11 RUBY_FAKEGEM_EXTRADOC="History.md README.md"
13 RUBY_FAKEGEM_GEMSPEC="cucumber.gemspec"
17 DESCRIPTION="Executable feature scenarios"
18 HOMEPAGE="https://github.com/aslakhellesoy/cucumber/wikis"
21 KEYWORDS="~alpha ~amd64 ~arm ~hppa ~ia64 ~ppc ~ppc64 ~sparc ~x86"
27 >=dev-ruby/rspec-2.13.0
28 >=dev-ruby/nokogiri-1.5.2
29 >=dev-ruby/syntax-1.0.0
30 >=dev-util/aruba-0.5.2
33 >=dev-util/cucumber-1.3
38 >=dev-ruby/builder-2.1.2
39 >=dev-ruby/diff-lcs-1.1.3
40 >=dev-ruby/gherkin-2.12.0:0
41 >=dev-ruby/multi_json-1.7.5
42 >=dev-ruby/multi_test-0.1.2
46 # Remove development dependencies from the gemspec that we don't
47 # need or can't satisfy.
48 sed -i -e '/\(spork\|simplecov\|bcat\|kramdown\|yard\|capybara\|rack-test\|ramaze\|sinatra\|webrat\|mime-types\|rubyzip\)/d' ${RUBY_FAKEGEM_GEMSPEC} || die
50 # Fix too-strict test dependencies
51 sed -e '/nokogiri/ s/~> 1.5.2/>= 1.5.2/' \
52 -e '/aruba/ s/= 0.5.2/~> 0.5/' \
53 -e '/rake/ s/10.2/10.5/' -i ${RUBY_FAKEGEM_GEMSPEC} || die
55 # Make sure spork is run in the right interpreter
56 sed -i -e 's/#{Spork::BINARY}/-S #{Spork::BINARY}/' features/support/env.rb || die
57 rm features/drb_server_integration.feature || die
59 # Avoid json, they most likely fail due to multi_json weirdness.
60 rm features/json_formatter.feature || die
61 # Avoid features that break with newer rspec versions.
62 sed -i -e '369,398d' features/background.feature || die
64 # Avoid dependency on git
65 sed -i -e '/git ls-files/d' cucumber.gemspec || die
70 RUBYLIB=lib ${RUBY} -Ilib bin/cucumber features || die "Features failed"
77 cp -pPR examples "${D}/usr/share/doc/${PF}" || die "Failed installing example files."