From 42fbe2d214b850ded06b23ca33f3aa2880e60dbb Mon Sep 17 00:00:00 2001 From: root Date: Fri, 20 Sep 2013 02:18:37 -0700 Subject: Fri Sep 20 02:14:49 PDT 2013 --- community/ruby-iconv/PKGBUILD | 26 +++++++++++++++++--------- 1 file changed, 17 insertions(+), 9 deletions(-) (limited to 'community/ruby-iconv') diff --git a/community/ruby-iconv/PKGBUILD b/community/ruby-iconv/PKGBUILD index d2b60d9ac..7fbd5a8e5 100755 --- a/community/ruby-iconv/PKGBUILD +++ b/community/ruby-iconv/PKGBUILD @@ -1,24 +1,32 @@ -# $Id: PKGBUILD 89242 2013-04-28 10:01:07Z alucryd $ -# Maintainer: Alucryd +# $Id: PKGBUILD 97425 2013-09-19 13:00:39Z alucryd $ +# Maintainer: Maxime Gauduin pkgname=ruby-iconv pkgver=1.0.3 -pkgrel=2 +pkgrel=3 pkgdesc="Wrapper library for iconv" arch=('i686' 'x86_64') url="https://github.com/nurse/iconv" -license=('GPL3') +license=('BSD') depends=('ruby') -makedepends=('rubygems') -options=('!emptydirs') source=("https://rubygems.org/downloads/${pkgname#*-}-${pkgver}.gem") +noextract=("${pkgname#*-}-${pkgver}.gem") sha256sums=('94a9b62a56c96226b62b787cd45fdc48c03f4517f1e36e64db113b010fb012da') +build() { + gem install --no-user-install --ignore-dependencies -i . ${pkgname#*-}-${pkgver}.gem +} + package() { - cd "${srcdir}" + local _rubyver="$(ruby --version | sed 's/.* \(.*\..*\..*\)p.*/\1/')" + install -dm 755 "${pkgdir}"/usr/lib/ruby/{gems/${_rubyver},vendor_ruby/${_rubyver}/$CARCH-linux} + mv gems/${pkgname#*-}-${pkgver}/lib/* "${pkgdir}"/usr/lib/ruby/vendor_ruby/${_rubyver}/ + mv doc specifications "${pkgdir}"/usr/lib/ruby/gems/${_rubyver}/ + mv "${pkgdir}"/usr/lib/ruby/vendor_ruby/${_rubyver}/{iconv,$CARCH-linux}/iconv.so - local _gemdir="$(ruby -rubygems -e 'puts Gem.default_dir')" - gem install --no-user-install --ignore-dependencies -i "${pkgdir}"${_gemdir} ${pkgname#*-}-${pkgver}.gem +# License + install -dm 755 "${pkgdir}"/usr/share/licenses/${pkgname} + install -m 644 {gems/${pkgname#*-}-${pkgver},"${pkgdir}"/usr/share/licenses/${pkgname}}/BSDL } # vim: ts=2 sw=2 et: -- cgit v1.2.3-54-g00ecf