Date: Wednesday, April 5, 2023 @ 02:13:58 Author: grawlinson Revision: 1435275
upgpkg: ruby-pkg-config 1.5.1-1; new upstream release Modified: ruby-pkg-config/trunk/PKGBUILD ----------+ PKGBUILD | 51 +++++++++++++++++++++++++++++++++++++++------------ 1 file changed, 39 insertions(+), 12 deletions(-) Modified: PKGBUILD =================================================================== --- PKGBUILD 2023-04-04 23:52:21 UTC (rev 1435274) +++ PKGBUILD 2023-04-05 02:13:58 UTC (rev 1435275) @@ -1,29 +1,56 @@ -# Maintainer: Alexander Rødseth <[email protected]> +# Maintainer: George Rawlinson <[email protected]> +# Contributor: Alexander Rødseth <[email protected]> # Contributor: Brad Fanella <[email protected]> # Contributor: gem2arch 0.1 # Contributor: theapodan pkgname=ruby-pkg-config -_pkgname=pkg-config -pkgver=1.4.9 +_pkgname="${pkgname#ruby-}" +pkgver=1.5.1 pkgrel=1 -pkgdesc='Implementation of pkg-config in ruby' +pkgdesc='Implementation of pkg-config in Ruby' arch=('any') -url='https://github.com/ruby-gnome2/pkg-config' +url='https://github.com/ruby-gnome/pkg-config' license=('LGPL') depends=('ruby') +makedepends=('git') provides=('ruby-pkgconfig') replaces=('ruby-pkgconfig') conflicts=('ruby-pkgconfig') -source=("https://rubygems.org/downloads/$_pkgname-$pkgver.gem") -sha256sums=('14968c3fec94a66f53a273b74478ed6372f2cf9a08bc081ba7642878ebac3b6d') -noextract=("$_pkgname-$pkgver.gem") +_commit='20285cd18aa7d9fe7d66cc99a81e3e7429fe3ad7' +source=("$pkgname::git+$url#commit=$_commit") +b2sums=('SKIP') +pkgver() { + cd "$pkgname" + + git describe --tags | sed 's/^v//' +} + +build() { + cd "$pkgname" + + gem build "$_pkgname.gemspec" +} + package() { + cd "$pkgname" + + local _gemdir="$(ruby -e'puts Gem.default_dir')" + gem install \ + --local \ + --verbose \ + --ignore-dependencies \ --no-user-install \ - --ignore-dependencies \ - --no-document \ - -i "$pkgdir$(ruby -e'puts Gem.default_dir')" \ - $_pkgname-$pkgver.gem + --install-dir "$pkgdir/$_gemdir" \ + --bindir "$pkgdir/usr/bin" \ + "$_pkgname-$pkgver.gem" + + # delete cache + rm -rf "$pkgdir/$_gemdir/cache" + + # license + install -vd "$pkgdir/usr/share/licenses/$pkgname" + ln -sf "$_gemdir/gems/$_pkgname-$pkgver/LGPL-2.1" "$pkgdir/usr/share/licenses/$pkgname" }
