#!/usr/bin/bash
# JOBoRun		: Jwm OpenBox Obarun RUNit
# Maintainer	: Joe Bo Run <joborun@disroot.org>
# PkgSource		: url="https://gittea.disroot.org/joborun-pkg/jobextra/$pkgname"
# Website		: https://pozol.eu
#-----------------------------------------| DESCRIPTION |---------------------------------------

pkgname=mpc
pkgver=0.34
pkgrel=03
pkgdesc="Minimalist command line interface to MPD"
url="https://www.musicpd.org/clients/mpc/"
depends=(glibc)
makedepends=(libmpdclient meson python-sphinx rsync)
# options=(debug)  ## uncomment to produce the debug pkg
source=(https://www.musicpd.org/download/${pkgname}/${pkgver%.*}/${pkgname}-${pkgver}.tar.xz{,.sig})

build() {
  arch-meson build $pkgname-$pkgver
  ninja -C build
}

package() {
  depends+=(libmpdclient.so)

  DESTDIR="$pkgdir" ninja -C build install
  install -vDm 644 $pkgname-$pkgver/contrib/mpc-completion.bash "$pkgdir/usr/share/bash-completion/completions/mpc"
  # the html documentation is not reproducible and only the man page is needed
  rm -rvf "$pkgdir/usr/share/doc/$pkgname/"{html,contrib/*.bash}
}

#---- arch license gpg-key & sha256sums ----

arch=(x86_64)

license=(GPL2)

validpgpkeys=('0392335A78083894A4301C43236E8A58C6DB4512') # Max Kellermann <max@blarg.de>

sha256sums=(691e3f3654bc10d022bb0310234d0bc2d8c075a698f09924d9ebed8f506fda20  # mpc-0.34.tar.xz
	11c88dc463286a1cf1f5c4293945f0a5642248b351576b06fab96881bbd92273) # mpc-0.34.tar.xz.sig

##  7a6f6873232aa83e894974a6cbf51e294a204131dedb2e7cc4d16222eb86dc81  mpc-0.34-03-x86_64.pkg.tar.lz


