summarylogtreecommitdiffstats
path: root/PKGBUILD
blob: 18be301c98d26a1cae5250fd5971bd090bc4faa0 (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
pkgname=cmos-git
pkgver=v1.0.r10.ga680c89
pkgrel=1
pkgdesc='Small markdown renderer based on CommonMark libcmark'
arch=(x86_64)
url='https://sr.ht/~bitfehler/cmos'
license=(MIT)
depends=(
  'libunistring'
  'cmark'
  'source-highlight'
)
makedepends=(git meson ninja)
provides=('cmos')
conflicts=('cmos')

source=("${pkgname}::git+https://git.sr.ht/~bitfehler/cmos")
sha512sums=('SKIP')

pkgver() {
  cd "${pkgname}"
  git describe --long --tags | sed 's/\([^-]*-g\)/r\1/;s/-/./g'
}

build() {
  mkdir -p build
  arch-meson build "$pkgname"
  ninja -C build
}

package() {
  DESTDIR="$pkgdir" ninja -C build install
  cd "${pkgname}"
  install -Dm644 LICENSE -t "$pkgdir/usr/share/licenses/$pkgname"
}

# vim: ts=2 sw=2 et