# $Id$
# Maintainer: Jan Alexander Steffens (heftig) <jan.steffens@gmail.com>
# Contributor: Stefan Husmann <stefan-husmann@t-online.de>
# Contributor:  <mathieu.clabaut@gmail.com>
# Maintainer: David P. <megver83@parabola.nu>

pkgname=xdg-user-dirs
pkgver=0.17
pkgrel=2
pkgrel+=.nonsystemd1
pkgdesc="Manage user directories like ~/Desktop and ~/Music"
arch=(x86_64 i686 armv7h)
url="https://www.freedesktop.org/wiki/Software/xdg-user-dirs"
license=(GPL)
depends=(sh)
makedepends=(docbook-xsl git)
backup=(etc/xdg/user-dirs.conf etc/xdg/user-dirs.defaults)
options=(!emptydirs)
_commit=ec015cdd345dec8025948533e7a6f18680e7f70c  # tags/0.17^0
source=("git+https://gitlab.freedesktop.org/xdg/xdg-user-dirs.git#commit=$_commit")
sha256sums=('SKIP')

pkgver() {
  cd $pkgname
  git describe --tags | sed 's/-/+/g'
}

prepare() {
  cd $pkgname
  NOCONFIGURE=1 ./autogen.sh
}

build() {
  cd $pkgname
  ./configure --prefix=/usr --sysconfdir=/etc
  make
}

package() {
  cd $pkgname
  make DESTDIR="$pkgdir" install
}
