aboutsummaryrefslogtreecommitdiffstats
path: root/community/ruby-rake-compiler/APKBUILD
diff options
context:
space:
mode:
authorJakub Jirutka <jakub@jirutka.cz>2017-12-26 01:30:05 +0100
committerJakub Jirutka <jakub@jirutka.cz>2017-12-26 01:30:05 +0100
commitcb6b327147d747c711cdfd000313d2ebbc64ea25 (patch)
treed3f006e78d02aec4955f8de94fbd6a663ee8ab49 /community/ruby-rake-compiler/APKBUILD
parentf45c2cffc7d8bad71c9a4134e9a22329a2248fc5 (diff)
downloadaports-cb6b327147d747c711cdfd000313d2ebbc64ea25.tar.bz2
aports-cb6b327147d747c711cdfd000313d2ebbc64ea25.tar.xz
community/ruby-rake-compiler: move from testing
Diffstat (limited to 'community/ruby-rake-compiler/APKBUILD')
-rw-r--r--community/ruby-rake-compiler/APKBUILD48
1 files changed, 48 insertions, 0 deletions
diff --git a/community/ruby-rake-compiler/APKBUILD b/community/ruby-rake-compiler/APKBUILD
new file mode 100644
index 0000000000..26f69b3af2
--- /dev/null
+++ b/community/ruby-rake-compiler/APKBUILD
@@ -0,0 +1,48 @@
+# Contributor: Jakub Jirutka <jakub@jirutka.cz>
+# Maintainer: Jakub Jirutka <jakub@jirutka.cz>
+pkgname=ruby-rake-compiler
+_gemname=${pkgname#ruby-}
+pkgver=1.0.4
+pkgrel=1
+pkgdesc="Provide a standard and simplified way to build and package Ruby extensions"
+url="https://github.com/rake-compiler/rake-compiler"
+arch="noarch"
+license="MIT"
+depends="ruby ruby-rake"
+checkdepends="ruby-rspec"
+source="$pkgname-$pkgver.tar.gz::https://github.com/rake-compiler/$_gemname/archive/v$pkgver.tar.gz
+ 0001-extract-gemspec.patch
+ gemfile-remove-unwanted-files.patch"
+builddir="$srcdir/$_gemname-$pkgver"
+
+build() {
+ cd "$builddir"
+ gem build $_gemname.gemspec
+}
+
+check() {
+ cd "$builddir"
+ rspec spec
+}
+
+package() {
+ local gemdir="$pkgdir/$(ruby -rubygems -e 'puts Gem.default_dir')"
+
+ cd "$builddir"
+
+ gem install --local \
+ --install-dir "$gemdir" \
+ --bindir "$pkgdir/usr/bin" \
+ --ignore-dependencies \
+ --no-document \
+ --verbose \
+ $_gemname
+
+ # Remove unnecessary files and empty directories.
+ cd "$gemdir"
+ rm -r cache build_info doc
+}
+
+sha512sums="fc015d8f6dcc2ba380dbc3eb2959b068f3582e0efcdc765570f5b2c97737db2ba38fb324b9b5bb63d3af822843139561a36758408db637e7716afb3a6074251c ruby-rake-compiler-1.0.4.tar.gz
+ea218d90f5651bdf46a96eaca2bc34f27ace9ff22752f5ce6ad9bb0d8bede110b212f797f1accd1fa3bd76ee093003269d8fcfc1490124bfa54785e92443a1dc 0001-extract-gemspec.patch
+e68672541d62898bc72fb7e40f16bc75ed1d46eabedd18da60a6f0673d67bf63d990e191fb41d6034e3f6361662807030cbd8f0c817223a5d03c46a3a664f855 gemfile-remove-unwanted-files.patch"