summarylogtreecommitdiffstats
path: root/PKGBUILD
blob: e5e62988786c8771e1dfd35f80ec565e79e9e72b (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
# Maintainer: Solomon Choina <shlomochoina@gmail.com>
pkgbase=hasl-hg
pkgname=(hasl-hg hasl-docs-hg)
pkgver=r59.ca6442534909
pkgrel=1
pkgdesc="The Hassle-free Authentication and Security Layer client library"
arch=("x86_64")
url="https://keep.imfreedom.org/hasl/hasl/"
license=('LGPL-2.1-or-later')
depends=(glib2 glibc libidn)
makedepends=(meson ninja mercurial gi-docgen gobject-introspection)
provides=('hasl')
source=("hg+https://keep.imfreedom.org/hasl/hasl")
sha256sums=('SKIP')
pkgver() {
	cd hasl
        printf "r%s.%s" "$(hg identify -n)" "$(hg identify -i)"

}

build() {
        arch-meson hasl build
	ninja -C build
}

_pick() {
  local p="$1" f d; shift
  for f; do
    d="$srcdir/$p/${f#$pkgdir/}"
    mkdir -p "$(dirname "$d")"
    mv "$f" "$d"
    rmdir -p --ignore-fail-on-non-empty "$(dirname "$f")"
  done
}

package_hasl-hg() {
  DESTDIR="$pkgdir/" ninja -C build install

  cd "$pkgdir"

   _pick docs usr/share/doc
}

package_hasl-docs-hg() {
   pkdesc+="  (documentation)"
   depends=()
   mv docs/* "$pkgdir"
 }