diff options
author | Hans de Graaff <graaff@gentoo.org> | 2021-10-17 08:28:33 +0200 |
---|---|---|
committer | Hans de Graaff <graaff@gentoo.org> | 2021-10-17 10:33:49 +0200 |
commit | 7f7acee10b2f0a5f20d96fa98dec4c2252de63b2 (patch) | |
tree | f52db8e5b9c1bff6977dd78e12373e887dc250b6 /dev-ruby/hiredis | |
parent | eclass/ruby-fakegem.eclass: provide PKG_CONFIG to extensions (diff) | |
download | gentoo-7f7acee10b2f0a5f20d96fa98dec4c2252de63b2.tar.gz gentoo-7f7acee10b2f0a5f20d96fa98dec4c2252de63b2.tar.bz2 gentoo-7f7acee10b2f0a5f20d96fa98dec4c2252de63b2.zip |
dev-ruby/hiredis: modernize
Use EAPI 8 and add new ruby targets. Properly install extensions.
Lock to older hiredis version since compiling against a newer
version results in segmentation faults.
Package-Manager: Portage-3.0.20, Repoman-3.0.3
Signed-off-by: Hans de Graaff <graaff@gentoo.org>
Diffstat (limited to 'dev-ruby/hiredis')
-rw-r--r-- | dev-ruby/hiredis/hiredis-0.6.3-r1.ebuild | 41 |
1 files changed, 41 insertions, 0 deletions
diff --git a/dev-ruby/hiredis/hiredis-0.6.3-r1.ebuild b/dev-ruby/hiredis/hiredis-0.6.3-r1.ebuild new file mode 100644 index 000000000000..96c59d55486e --- /dev/null +++ b/dev-ruby/hiredis/hiredis-0.6.3-r1.ebuild @@ -0,0 +1,41 @@ +# Copyright 1999-2021 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=8 + +USE_RUBY="ruby26 ruby27 ruby30" + +MY_P="hiredis-rb-${PV}" + +RUBY_FAKEGEM_RECIPE_DOC="rdoc" +RUBY_FAKEGEM_EXTRADOC="CHANGELOG.md README.md" + +RUBY_FAKEGEM_EXTENSIONS=(ext/hiredis_ext/extconf.rb) +RUBY_FAKEGEM_EXTENSION_LIBDIR="lib/hiredis/ext" + +inherit ruby-fakegem + +DESCRIPTION="Wrapper for hiredis (protocol serialization/deserialization and blocking I/O)" +HOMEPAGE="https://github.com/redis/hiredis-rb" +SRC_URI="https://github.com/redis/hiredis-rb/archive/v${PV}.tar.gz -> ${MY_P}.tar.gz" + +LICENSE="BSD" +SLOT="0" +KEYWORDS="~amd64" +IUSE="" + +RDEPEND+=" =dev-libs/hiredis-0.14*:=" +DEPEND+=" dev-libs/hiredis test? ( dev-ruby/test-unit:2 )" +DEPEND+=" virtual/pkgconfig" + +RUBY_S="${MY_P}" + +PATCHES=( "${FILESDIR}/${PN}-0.6.1-unvendor-hiredis.patch" ) + +all_ruby_prepare() { + sed -i -e 's:/tmp/:'${T}'/:' test/connection_test.rb || die +} + +each_ruby_test() { + ${RUBY} -Ilib:. -e 'Dir["test/*_test.rb"].each{|f| require f}' || die +} |