git » liblo.git » commit fb6f57d

Rebuild to re-sign package.

author David Runge
2023-03-23 22:42:57 UTC
committer David Runge
2023-03-23 22:42:57 UTC
parent 264b6287c89c95486304c51ba7b33591ef3cdfd4

Rebuild to re-sign package.

Remove unnecessary quotes and curly braces.
Split out documentation to save space.
Simplify make calls.

PKGBUILD +20 -18

diff --git a/PKGBUILD b/PKGBUILD
index 2ac3193..8d8e49b 100644
--- a/PKGBUILD
+++ b/PKGBUILD
@@ -1,18 +1,17 @@
 # Maintainer: David Runge <dvzrv@archlinux.org>
 # Contributor: Ray Rashif <schiv@archlinux.org>
 
-pkgname=liblo
+pkgbase=liblo
+pkgname=(liblo liblo-docs)
 pkgver=0.31
-pkgrel=2
+pkgrel=3
 epoch=1
 pkgdesc="A lightweight OSC (Open Sound Control) implementation"
 arch=(x86_64)
 url="http://liblo.sourceforge.net/"
 license=(LGPL2.1)
-depends=(glibc)
 makedepends=(doxygen)
-provides=(liblo.so)
-source=($pkgname-$pkgver.tar.gz::https://github.com/radarsat1/$pkgname/archive/$pkgver.tar.gz)
+source=(https://github.com/radarsat1/$pkgname/archive/$pkgver/$pkgname-$pkgver.tar.gz)
 sha512sums=('328d413a6608e5e99d41bfc5a153ef10510e79589cb4d8df4511c8187b8baa6fd8f8c2fd3fe54de7736855f699619d4ebc088a17acf8700085b59ee38ade7d21')
 b2sums=('0dcec43175a960fbb56a0082bed64dd55dd2f40b0a1b0356222cc25ea6212109ca6626656ce6030625a3bc02b9383a8691ea163fc4e401f2c4003dbf34bc5837')
 
@@ -30,20 +29,23 @@ build() {
   make
 }
 
-package() {
-  cd $pkgname-$pkgver
-  make DESTDIR="$pkgdir" install
+package_liblo() {
+  depends=(glibc)
+  optdepends=(
+    'liblo-docs: for documentation and examples'
+  )
+  provides=(liblo.so)
+
+  make DESTDIR="$pkgdir" install -C $pkgname-$pkgver
+  install -vDm 644 $pkgname-$pkgver/doc/man/man3/*.3 -t "$pkgdir/usr/share/man/man3"
+}
 
-  # delete broken man pages
-  rm -f doc/man/man3/_*.3
+package_liblo-docs() {
+  pkgdesc+=" - documentation"
 
-  # man pages
-  install -vDm 644 doc/man/man3/*.3 -t "$pkgdir/usr/share/man/man3"
-  # examples
-  install -vDm 644 examples/*.{cpp,c} -t "$pkgdir/usr/share/$pkgname/examples/"
-  # docs
-  install -vDm 644 doc/html/* -t "$pkgdir/usr/share/doc/$pkgname/html/"
-  install -vDm 644 doc/latex/* -t "$pkgdir/usr/share/doc/$pkgname/latex/"
-  install -vDm 644 {AUTHORS,ChangeLog,NEWS,README.md,TODO} -t "$pkgdir/usr/share/doc/$pkgname/"
+  install -vDm 644 $pkgbase-$pkgver/examples/*.{cpp,c} -t "$pkgdir/usr/share/$pkgbase/examples/"
+  install -vDm 644 $pkgbase-$pkgver/doc/html/* -t "$pkgdir/usr/share/doc/$pkgbase/html/"
+  install -vDm 644 $pkgbase-$pkgver/doc/latex/* -t "$pkgdir/usr/share/doc/$pkgbase/latex/"
+  install -vDm 644 $pkgbase-$pkgver/{AUTHORS,ChangeLog,NEWS,README.md,TODO} -t "$pkgdir/usr/share/doc/$pkgbase/"
 }
 # vim:set ts=2 sw=2 et: