summarylogtreecommitdiffstats
path: root/PKGBUILD
blob: f12d4d48ad1a5c24fea6b306b484341566eaf6d6 (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
# Maintainer: Abdó Roig-Maranges <abdo.roig@gmail.com>

pkgname=extempore-git
pkgver=0.7.0.r251.g9ff1bb32
pkgrel=1
pkgdesc="A cyber-physical programming environment for live coding"
arch=('i686' 'x86_64')
url="http://extempore.moso.com.au"
license=('BSD')
depends=('mesa' 'pcre' 'alsa-lib')
makedepends=('git' 'cmake' 'gcc' 'perl')
optdepends=('jack')
provides=('extempore')
conflicts=('extempore')
source=("git+https://github.com/digego/extempore.git")
md5sums=('SKIP')

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

prepare() {
  cd "${srcdir}/extempore"

  # Do not hook up aot_extended on ALL. Otherwise it is run at make install,
  # since it does not track build products.
  sed -i 's/aot_extended ALL/aot_extended/g' CMakeLists.txt
}

build() {
  mkdir -p "${srcdir}/build"
  cd "${srcdir}/build"

  cmake -DCMAKE_INSTALL_PREFIX=/opt \
        -DJACK=ON \
        -DBUILD_DEPS=ON \
        -DPACKAGE=ON \
        ../extempore

  make extempore aot_extended assets
}

package() {
  cd "${srcdir}/build"

  make DESTDIR="${pkgdir}/" install

  # emacs and vim files
  install -D "${srcdir}/extempore/extras/extempore.el" "${pkgdir}/usr/share/emacs/site-lisp/extempore/extempore.el"
  install -D "${srcdir}/extempore/extras/extempore.vim" "${pkgdir}/usr/share/vim/vimfiles/plugin/extempore.vim"

  install -d "${pkgdir}/usr/bin"
  ln -s /opt/extempore/extempore "${pkgdir}/usr/bin/extempore"
}


# vim:set ts=2 sw=2 et: