1
0
Fork 0
mirror of https://gitlab.alpinelinux.org/alpine/aports.git synced 2025-07-24 03:35:38 +03:00
aports/testing/ruby-rb-inotify/APKBUILD
2021-06-29 22:33:04 +02:00

54 lines
1.4 KiB
Text

# Contributor: Jakub Jirutka <jakub@jirutka.cz>
# Maintainer: Jakub Jirutka <jakub@jirutka.cz>
pkgname=ruby-rb-inotify
_gemname=rb-inotify
pkgver=0.10.1
pkgrel=0
pkgdesc="A Ruby wrapper for Linux inotify, using FFI"
url="https://github.com/guard/rb-inotify"
arch="noarch"
license="MIT"
depends="ruby ruby-ffi"
checkdepends="ruby-concurrent-ruby ruby-rspec"
source="https://github.com/guard/rb-inotify/archive/v$pkgver/$pkgname-$pkgver.tar.gz
gemspec.patch
"
builddir="$srcdir/$_gemname-$pkgver"
prepare() {
default_prepare
# Bundler is not necessary.
sed -i '/require .bundler\/setup/d' spec/spec_helper.rb
}
build() {
gem build $_gemname.gemspec
}
check() {
# Bunler needs "Pathname" for its functionality, but we are not using Bundler,
# therefore we need to load it explicitly.
rspec -rpathname .
}
package() {
local gemdir="$pkgdir/$(ruby -e 'puts Gem.default_dir')"
gem install \
--local \
--install-dir "$gemdir" \
--ignore-dependencies \
--no-document \
--verbose \
$_gemname
# Remove unnecessary files and rubbish...
cd "$gemdir"
rm -r cache build_info doc
}
sha512sums="
fb8484b3c019ff471dbea57ad305c32a9d03377f8bbcb4d1631ef498b3207bc83da08889f7d43fe3a9ba54df2d9164e3a83d001797f8113ddc2e3a7f2ad9a83b ruby-rb-inotify-0.10.1.tar.gz
2d9896ee5a81bc74d8921c4773771cf966dd5b164f6949857671afd2152a791377a18dd3c71cad7aefcd1d1d2f2b70fd366873f80269c672e750618e8e90e727 gemspec.patch
"