summarylogtreecommitdiffstats
path: root/PKGBUILD
blob: ccf7be89a6128e73d695fbf20795cd4eb569b7ef (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
# Maintainer: Daniel Appelt <daniel.appelt@gmail.com>
_pkgbasename=distrho-extra-lv2
pkgname=${_pkgbasename}-git
pkgver=r26.b6f25f1
pkgrel=1
pkgdesc="Extra LV2 ports of JUCE-based audio plugins using the DISTRHO framework"
arch=('i686' 'x86_64')
url="http://distrho.sourceforge.net/"
license=('GPL' 'MIT')
depends=('lv2' 'freetype2' 'libxext')
makedepends=('git' 'premake3')
provides=("${_pkgbasename}")
conflicts=("${_pkgbasename}")
source=("${_pkgbasename%%-*}::git://github.com/DISTRHO/DISTRHO-Ports.git"
	"${_pkgbasename}::git://github.com/DISTRHO/DISTRHO-Ports-Extra.git")
sha256sums=('SKIP'
	    'SKIP')

pkgver() {
  cd "${srcdir}/${_pkgbasename}"

  printf "r%s.%s" "$(git rev-list --count HEAD)" "$(git rev-parse --short HEAD)"
}

# TODO: make DISTRHO-Ports a dependency instead of having to build it in here
prepare() {
  cd "${srcdir}/${_pkgbasename%%-*}"

  # generate build script
  scripts/premake-update.sh linux
  make
  
  cd "${srcdir}/${_pkgbasename}"

  # redefine links to DISTRHO libs and scripts
  ln -f -s "${srcdir}/${_pkgbasename%%-*}/libs"
  ln -f -s "${srcdir}/${_pkgbasename%%-*}/scripts"
  
  # generate build script
  scripts/premake-update.sh linux
}

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

  make lv2
}

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

  # lv2 plugins
  install -d "$pkgdir/usr/lib/lv2"
  cp -a bin/lv2/*.lv2 "$pkgdir/usr/lib/lv2"
}