dev-ruby/libusb: add 0.7.0

Signed-off-by: Hans de Graaff <graaff@gentoo.org>
This commit is contained in:
Hans de Graaff
2024-04-19 08:30:50 +02:00
parent e576c0446d
commit 9da9b51603
2 changed files with 47 additions and 0 deletions
+1
View File
@@ -1 +1,2 @@
DIST libusb-0.6.4.gem 762368 BLAKE2B daca8049b82cb56fb8cac350f6953ce292c74370bf468497773b34b6017eef9c0252daf2a0213e660db99120a53193ea67943bb1d851ae1ee723ea84dbe289e0 SHA512 433425f9cc2600615a3e4baec962ff0901e9c0eae7a77c410d099f22742995b23bf9c143797b393843b3de26b8336263cd5b3d3d1cdcd8f91266d90201a6a6de
DIST libusb-0.7.0.gem 819712 BLAKE2B a8d85731b3cff2a5ddf9391a01c54250f11b9933e7ea429031cf8879e22ee79c8c3c8669735b73b7e32ca56c77245588511df1d486a17da67215af2d052082aa SHA512 cd17e40b34bf5015e43435f8f510ce63bc2434c77680dcc8079f123ec4bb12b22b92ae59a7c8646747e5be7f6d14bf3f3a1302549e686ab3735966987311481a
+46
View File
@@ -0,0 +1,46 @@
# Copyright 2022-2024 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI=8
USE_RUBY="ruby31 ruby32"
RUBY_FAKEGEM_EXTRADOC="History.md README.md"
RUBY_FAKEGEM_GEMSPEC="${PN}.gemspec"
inherit ruby-fakegem
DESCRIPTION="binding that gives Ruby programmers access to arbitrary USB devices"
HOMEPAGE="https://github.com/larskanis/libusb"
LICENSE="BSD"
SLOT="0"
KEYWORDS="~amd64 ~x86"
DEPEND+=">=dev-libs/libusb-1.0.27:1"
RDEPEND+="${DEPEND}"
ruby_add_rdepend "dev-ruby/ffi:0"
ruby_add_bdepend "test? ( dev-ruby/eventmachine )"
all_ruby_prepare() {
sed -e '/mini_portile2/d' \
-e 's/git ls-files --/find/' \
-i ${RUBY_FAKEGEM_GEMSPEC} || die
# Avoid tests that try to open devices or depend on specific hardware
rm -f test/test_libusb_{bos,bulk_stream_transfer,descriptors}.rb || die
}
each_ruby_test() {
${RUBY} -I.:lib -e "Dir['test/test_*.rb'].each{|f| require f}" || die
}
each_ruby_install() {
each_fakegem_install
# This gem includes an extension that does not actually do anything
# when using the system libusb, but newer rubygems versions still
# require the marker to be present.
ruby_fakegem_extensions_installed
}