summarylogtreecommitdiffstats
path: root/PKGBUILD
blob: 8d26e805242f0f36c7fa5b3acb2b393486da6372 (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
# Maintainer: Eric Engestrom <aur [at] engestrom [dot] ch>

pkgname=cmb
pkgver=3.9.5
pkgrel=1
pkgdesc="combinatorics utility"
url="https://fraubsd.org/cmb"
arch=('x86_64')
license=('BSD')
makedepends=('awk' 'libcmb')
depends=('openssl' 'libcmb')
source=("git+https://github.com/FrauBSD/pkgcenter")
sha256sums=('SKIP')

pkgver() {
  cd pkgcenter/depend/cmb
  awk 'match($$0, /\$Version: [^$]* \$/) {
         print substr($0, RSTART + 10, RLENGTH - 12);
         exit found=1;
       } END { exit !found }' cmb.c |
  sed s/-/./g
}

build() {
  cd pkgcenter/depend/cmb
  ./configure --prefix "$pkgdir/usr"
  make || msg2 "Try upgrading libcmb and building cmb again afterwards"
}

package() {
  cd pkgcenter/depend/cmb
  make install
}