diff options
-rw-r--r-- | main/ruby-pg/APKBUILD | 32 |
1 files changed, 18 insertions, 14 deletions
diff --git a/main/ruby-pg/APKBUILD b/main/ruby-pg/APKBUILD index 16e7e86ff5..6a76343645 100644 --- a/main/ruby-pg/APKBUILD +++ b/main/ruby-pg/APKBUILD @@ -1,32 +1,36 @@ # Contributor: Carlo Landmeter <clandmeter@gmail.com> # Maintainer: pkgname=ruby-pg -_realname=$pkgname -pkgver=0.7.9.2008.01.28 -pkgrel=1 +_gemname=pg +pkgver=0.14.1 +pkgrel=0 pkgdesc="PostgreSQL API module for Ruby" url="http://rubygems.org/gems/ruby-pg" arch="all" license="GPL" depends="ruby" depends_dev="postgresql-dev ruby-dev" -makedepends="$depends_dev rubygems" +makedepends="$depends_dev ruby-gems" install="" subpackages="" -source="" +source="http://gems.rubyforge.org/gems/$_gemname-$pkgver.gem" _builddir="$srcdir"/$_realname-$pkgver - build() { - mkdir -p "$_builddir" || return 1 - local _gemdir="$(ruby -rubygems -e'puts Gem.default_dir')" - gem install $_realname -v $pkgver -i "$_builddir"$_gemdir \ - --ignore-dependencies --verbose \ - --no-rdoc --no-ri || return 1 - rm -rf "$_builddir"$_gemdir/cache/ + return 0 } package() { - mkdir -p "$pkgdir" || return 1 - cp -ra "$_builddir"/* "$pkgdir"/ || return 1 + 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 || return 1 + rm -rf "$pkgdir"/$_gemdir/cache \ + "$pkgdir"/$_geminstdir/ext \ + "$pkgdir"/$_geminstdir/.require_paths } + +md5sums="1499fd3f3610e6e6b6a70296012b83ed pg-0.14.1.gem" |