diff options
author | Hans de Graaff <graaff@gentoo.org> | 2020-11-11 07:09:27 +0100 |
---|---|---|
committer | Hans de Graaff <graaff@gentoo.org> | 2020-11-11 07:09:27 +0100 |
commit | 6a92f88f3e37c771b3441910dfc715500c8a4761 (patch) | |
tree | b3502e06c48f1d673a8a5f48090338c7a623675e /dev-ruby/parallel | |
parent | eclass/cargo.eclass: clarify variable docs (diff) | |
download | gentoo-6a92f88f3e37c771b3441910dfc715500c8a4761.tar.gz gentoo-6a92f88f3e37c771b3441910dfc715500c8a4761.tar.bz2 gentoo-6a92f88f3e37c771b3441910dfc715500c8a4761.zip |
dev-ruby/parallel: add 1.20.0
Package-Manager: Portage-3.0.8, Repoman-3.0.2
Signed-off-by: Hans de Graaff <graaff@gentoo.org>
Diffstat (limited to 'dev-ruby/parallel')
-rw-r--r-- | dev-ruby/parallel/Manifest | 1 | ||||
-rw-r--r-- | dev-ruby/parallel/parallel-1.20.0.ebuild | 56 |
2 files changed, 57 insertions, 0 deletions
diff --git a/dev-ruby/parallel/Manifest b/dev-ruby/parallel/Manifest index fbc3836dad62..d4f9c78f10ae 100644 --- a/dev-ruby/parallel/Manifest +++ b/dev-ruby/parallel/Manifest @@ -1 +1,2 @@ DIST parallel-1.19.2.tar.gz 21752 BLAKE2B aac6564ad95d8e366ad079854f22e7dcb149643db5792ee81c84c8c765185e367dedd0e635d2373aeefcd84997da89f9f9f4f6c398e753af4a1ddbf90e428dd0 SHA512 192ce4dc18ecb47522360d0d7022a9e20d72e90ad09889f1b7f29c20c74c980319956f316a35aad0fc7efcd8aac5a635da69eebcf78ba34659365df20e402c3c +DIST parallel-1.20.0.tar.gz 20598 BLAKE2B f9e8626bf6430fffecd9aafb54e0c8c4b61f70dd58f7a2faee0e4c83c10c19d8eac419ab3e22fb75942a5c63f729d47d5e64683caa7f24bc304a1cb16862e18c SHA512 dc472a4792bea7b22b6613942a9c640437cb332d879406af2fad3de0f0529983ba92e6ee2e6f2d424e57695f238d44bf6987c6edc3ce5afca4b024b7501d9508 diff --git a/dev-ruby/parallel/parallel-1.20.0.ebuild b/dev-ruby/parallel/parallel-1.20.0.ebuild new file mode 100644 index 000000000000..e49b4e4213b2 --- /dev/null +++ b/dev-ruby/parallel/parallel-1.20.0.ebuild @@ -0,0 +1,56 @@ +# Copyright 1999-2020 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=7 + +USE_RUBY="ruby25 ruby26 ruby27" + +RUBY_FAKEGEM_RECIPE_TEST="rspec3" + +RUBY_FAKEGEM_EXTRAINSTALL="Readme.md" + +RUBY_FAKEGEM_GEMSPEC="parallel.gemspec" + +inherit ruby-fakegem + +DESCRIPTION="Run any code in parallel Processes or Threads" +HOMEPAGE="https://github.com/grosser/parallel" +LICENSE="MIT" +SRC_URI="https://github.com/grosser/parallel/archive/v${PV}.tar.gz -> ${P}.tar.gz" + +KEYWORDS="~amd64" +SLOT="1" +IUSE="test" + +DEPEND+="test? ( sys-process/lsof sys-process/procps )" + +ruby_add_bdepend " + test? ( dev-ruby/ruby-progressbar dev-ruby/activerecord:6.0 dev-ruby/sqlite3 )" + +each_ruby_prepare() { + # Make sure the correct ruby is used for testing + sed -e 's:ruby :'${RUBY}' :' -i spec/parallel_spec.rb || die +} + +all_ruby_prepare() { + sed -i -e 's/git ls-files/find/' ${RUBY_FAKEGEM_GEMSPEC} || die + sed -i -e '/bundler/ s:^:#:' \ + -e '1i require "tempfile"; gem "activerecord", "~>6.0.0"' spec/cases/helper.rb || die + sed -i -e '3irequire "timeout"' spec/spec_helper.rb || die + + # Avoid a failing spec regarding to pipes. The spec seems like it + # should always fail. + sed -e '/does not open unnecessary pipes/,/end/ s:^:#:' \ + -i spec/parallel_spec.rb || die + + # Avoid fragile ar sqlite tests. They throw ReadOnly errors every now and then. + sed -i -e '/works with SQLite in/,/end/ s:^:#:' spec/parallel_spec.rb || die + + # Avoid spec broken on Ruby 2.1 that clearly doesn't match code and doesn't really test anything + sed -i -e '/doesnt use Etc.nprocessors in Ruby 2.1 and below/,/end/ s:^:#:' spec/parallel_spec.rb || die +} + +each_ruby_test() { + # Set RUBYLIB explicitly for the ruby's that get started from the specs. + TRAVIS=true RUBYLIB="lib" ${RUBY} -S rspec-3 spec || die +} |