summarylogtreecommitdiffstats
path: root/PKGBUILD
blob: 6e79d7429b9a8c3bcaf0bc62825ac2b199070dfa (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
50
51
52
53
54
55
56
57
58
59
60
61
62
# Maintainer: Lucas Werkmeister <mail@lucaswerkmeister.de>
pkgname=dgsh-git
pkgver=r1568.e51fb99911
pkgrel=1
pkgdesc="Directed Graph Shell"
arch=('any')
url="https://www2.dmst.aueb.gr/dds/sw/dgsh/"
license=('Apache')
depends=()
makedepends=(
    'make'
    'automake'
    'gcc'
    'gperf'
    'libtool'
    'pkg-config'
    'texinfo'
    'help2man'
    'gettext'
    'git'
    'bison'
    'rsync'
)
checkdepends=(
    'check'
    'words'
    'fftw'
    'tcsh'
)
optdepends=(
    'graphviz: visualize graphs'
)
source=('git+https://github.com/dspinellis/dgsh.git')
md5sums=('SKIP')

pkgver() {
    cd 'dgsh'
    printf "r%s.%s" "$(git rev-list --count HEAD)" "$(git rev-parse --short HEAD)"
}

prepare() {
    cd 'dgsh'
    git submodule update --init
}

build() {
    cd 'dgsh'
    make $MAKEFLAGS PREFIX="/usr" config
    make $MAKEFLAGS
}

check() {
    cd 'dgsh'
    make $MAKEFLAGS -j1 test # tests must be run sequentially, so override any -jN in $MAKEFLAGS
}

package() {
    cd 'dgsh'
    make DESTDIR="$pkgdir/" install
    # the build leaves over some empty directories and sometimes the permissions differ, which produces warnings on install, so clean those up
    find "$pkgdir" -type d -empty -delete
}