diff options
author | Hans de Graaff <graaff@gentoo.org> | 2023-04-19 08:35:28 +0200 |
---|---|---|
committer | Hans de Graaff <graaff@gentoo.org> | 2023-04-19 21:04:03 +0200 |
commit | 0cc7c565765752bbf93d866d76ca3e685dd01001 (patch) | |
tree | e24acfa273440ace7f64d7b804ff6de3c96b24b9 /dev-ruby | |
parent | net-wireless/bluez: remove unused patch (diff) | |
download | gentoo-0cc7c565765752bbf93d866d76ca3e685dd01001.tar.gz gentoo-0cc7c565765752bbf93d866d76ca3e685dd01001.tar.bz2 gentoo-0cc7c565765752bbf93d866d76ca3e685dd01001.zip |
dev-ruby/parallel: add 1.23.0
Signed-off-by: Hans de Graaff <graaff@gentoo.org>
Diffstat (limited to 'dev-ruby')
-rw-r--r-- | dev-ruby/parallel/Manifest | 1 | ||||
-rw-r--r-- | dev-ruby/parallel/parallel-1.23.0.ebuild | 57 |
2 files changed, 58 insertions, 0 deletions
diff --git a/dev-ruby/parallel/Manifest b/dev-ruby/parallel/Manifest index 46e586bb6498..a1bb10585b40 100644 --- a/dev-ruby/parallel/Manifest +++ b/dev-ruby/parallel/Manifest @@ -1 +1,2 @@ DIST parallel-1.22.1.tar.gz 23294 BLAKE2B 11a3f902f8a6813b407035088adaf76fda5f27e0e33e7f210ce28fc66f4edf4f8d92a8b0f9501d24013a527f4205b79c6eda2c31f6fa4a646a18e6da5b20e702 SHA512 f106ac605a5998d0e5a43b7863f8400e49270c06e55b6342a84fed788e1e854a26a5e29ec31da9d96a4d403227d002691e27786c25e8d7542f3877bf097e55ad +DIST parallel-1.23.0.tar.gz 23359 BLAKE2B f7c505484a8ebade97efb61eb18474625ee994e3a4a16e85b264988212e3de093ae7b8cb03de2a6f97f8205b41264b72c13f32d81ed9ddcd2241d3aab15c7564 SHA512 fd80b928ad4c34c71abb62a2e27da6bdcabb425ed68cfef190c0e9f56c853147b1c96d7e9b5ec0ef2e7909dd2303892cb293c40a170241158286f9422b6bc780 diff --git a/dev-ruby/parallel/parallel-1.23.0.ebuild b/dev-ruby/parallel/parallel-1.23.0.ebuild new file mode 100644 index 000000000000..2777e7bdab14 --- /dev/null +++ b/dev-ruby/parallel/parallel-1.23.0.ebuild @@ -0,0 +1,57 @@ +# Copyright 1999-2023 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=8 + +USE_RUBY="ruby30 ruby31 ruby32" + +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" +SRC_URI="https://github.com/grosser/parallel/archive/v${PV}.tar.gz -> ${P}.tar.gz" + +LICENSE="MIT" +SLOT="1" +KEYWORDS="~amd64 ~riscv" + +DEPEND+="test? ( sys-process/lsof sys-process/procps )" + +ruby_add_bdepend " + test? ( dev-ruby/ruby-progressbar ) +" + +# Rails isn't yet ruby32-ready in Gentoo +USE_RUBY="ruby30 ruby31" ruby_add_bdepend " + test? ( dev-ruby/activerecord[sqlite] ) +" + +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"' spec/cases/helper.rb || die + sed -i -e '3irequire "timeout"' spec/spec_helper.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 +} + +each_ruby_test() { + if ! has_version -b "dev-ruby/activerecord[sqlite]" ; then + rm spec/cases/map_with_ar.rb spec/cases/each_with_ar_sqlite.rb || die + fi + + # Set RUBYLIB explicitly for the ruby's that get started from the specs. + TRAVIS=true RUBYLIB="lib" ${RUBY} -S rspec-3 spec || die +} |