1 # Copyright 1999-2019 Gentoo Authors
2 # Distributed under the terms of the GNU General Public License v2
5 PYTHON_COMPAT=( python{2_7,3_5,3_6,3_7} )
6 USE_RUBY="ruby23 ruby24 ruby25 ruby26"
8 RUBY_FAKEGEM_NAME="RbST"
9 RUBY_FAKEGEM_GEMSPEC="RbST.gemspec"
11 inherit python-single-r1 ruby-fakegem
13 DESCRIPTION="A simple Ruby wrapper for processing rST via docutils"
14 HOMEPAGE="https://github.com/alphabetum/rbst"
15 SRC_URI="https://github.com/alphabetum/rbst/archive/${PV}.tar.gz -> ${P}.tar.gz"
22 REQUIRED_USE="${PYTHON_REQUIRED_USE}"
24 RDEPEND="dev-python/docutils ${PYTHON_DEPS}"
25 DEPEND="test? ( ${RDEPEND} )"
29 >=dev-ruby/mocha-1.1.0:1.0
30 >=dev-ruby/shoulda-3.5.0:3
31 >=dev-ruby/test-unit-3.0.9:2
34 # Tests are pretty much useless as they depend on very specific output
35 # from an unknown docutils version.
39 python-single-r1_pkg_setup
45 sed -i -e '/bundler/,/end/d' \
46 Rakefile test/helper.rb || die
48 # force our python version
49 sed -i -e "s:\(python_path=\"\)python:\1${EPYTHON}:" lib/rbst.rb || die
50 python_fix_shebang lib/rst2parts