aboutsummaryrefslogtreecommitdiffstats
path: root/testing/ruby-nokogiri
diff options
context:
space:
mode:
authorJakub Jirutka <jakub@jirutka.cz>2017-03-25 01:43:45 +0100
committerJakub Jirutka <jakub@jirutka.cz>2017-03-25 18:00:26 +0100
commitfa4a6bacd13e4616d8b92ab6e296c5783eef52fa (patch)
tree75d4fd3feeddec13696fd0c770e60966988969ae /testing/ruby-nokogiri
parent0a53278913b208bc94d677208ad6ce98ae825737 (diff)
downloadaports-fa4a6bacd13e4616d8b92ab6e296c5783eef52fa.tar.bz2
aports-fa4a6bacd13e4616d8b92ab6e296c5783eef52fa.tar.xz
testing/ruby-nokogiri: move from testing and take maintainership
This is a gem with native extension (compiled C code) that depends on some system libraries. It's known to be quite problematic, so better to an aport for it. It will be used as check-dependency in ruby-mathematical (yet another quite problematic gem with native extension).
Diffstat (limited to 'testing/ruby-nokogiri')
-rw-r--r--testing/ruby-nokogiri/APKBUILD46
1 files changed, 46 insertions, 0 deletions
diff --git a/testing/ruby-nokogiri/APKBUILD b/testing/ruby-nokogiri/APKBUILD
new file mode 100644
index 0000000000..4e64dedf80
--- /dev/null
+++ b/testing/ruby-nokogiri/APKBUILD
@@ -0,0 +1,46 @@
+# Contributor: Fabian Affolter <fabian@affolter-engineering.ch>
+# Maintainer: Jakub Jirutka <jakub@jirutka.cz>
+_gemname=nokogiri
+pkgname=ruby-$_gemname
+pkgver=1.6.7.2
+pkgrel=1
+pkgdesc="An HTML, XML, SAX, and Reader parser"
+url="http://nokogiri.org/"
+arch="all"
+license="MIT"
+depends="ruby ruby-mini_portile2"
+depends_dev=""
+makedepends="ruby-dev libxml2-dev libxslt-dev"
+install=""
+subpackages=""
+source="http://gems.rubyforge.org/gems/$_gemname-$pkgver.gem"
+
+build() {
+ return 0
+}
+
+package() {
+ local _gemdir="$(ruby -rubygems -e'puts Gem.default_dir')"
+ local _geminstdir=$_gemdir/gems/$_gemname-$pkgver
+ mkdir -p "$pkgdir" || return 1
+
+ gem install --local --install-dir "$pkgdir"/$_gemdir \
+ --ignore-dependencies --verbose --no-rdoc --no-ri \
+ "$srcdir"/$_gemname-$pkgver.gem -- --use-system-libraries || \
+ return 1
+ rm -rf "$pkgdir"/$_gemdir/cache \
+ "$pkgdir"/$_geminstdir/ext \
+ "$pkgdir"/$_geminstdir/.require_paths
+
+ cd "$pkgdir"
+ for i in usr/lib/ruby/gems/*/bin/*; do
+ if [ -e "$i" ]; then
+ mkdir -p "$pkgdir"/usr/bin
+ ln -s /$i "$pkgdir"/usr/bin/
+ fi
+ done
+}
+
+md5sums="3e2169ebd67863a8a992289e2a887366 nokogiri-1.6.7.2.gem"
+sha256sums="fb6afc0faec72b82eeccc84b5d11211aa6c4a81898a433b499ca7a60fcad4b87 nokogiri-1.6.7.2.gem"
+sha512sums="27f72763f4f572b9a7042b48bd3a7a7516773eda128be603b8316e8ecaef42028f3d3a190947011cc6973fa4a43265a56f4b563bf28a8b2739b470cc19cee6cd nokogiri-1.6.7.2.gem"