pkgname=stk pkgver=4.5.1 pkgrel=1 pkgdesc='The Synthesis ToolKit in C++' arch=('x86_64') url='http://ccrma.stanford.edu/software/stk/' license=('MIT') depends=('gcc-libs' 'jack') makedepends=('pkg-config') optdepends=('tk: run provided demos/samples') source=("http://ccrma.stanford.edu/software/stk/release/$pkgname-$pkgver.tar.gz" "$pkgname.license" runtime.patch) sha1sums=('138c2504dbc12b60b676feb58a03d49a8412a036' '175eff9fade08cf871799335acfebd4b8d023979' '962bf8c9ed71d79cddaf1d391d59fd8c44a58fbb') build() { cd "$srcdir/$pkgname-$pkgver" # add missing linker flag export LIBS="$LIBS -lpthread" # enable shared library sed -i 's/all : $(STATICLIB)/all : $(SHAREDLIB)/' src/Makefile.in # fix demo rawwaves path sed -i 's:\.\./\.\.:/usr/lib/stk:' projects/demo/demo.cpp # run actual build ./configure RAWWAVE_PATH=/usr/lib/stk/rawwaves/ --prefix=/usr --with-alsa --with-jack make # fix executable scripts patch -Np1 -i ../runtime.patch } package() { cd "$srcdir/$pkgname-$pkgver" make DESTDIR="${pkgdir}" install # install license install -Dm644 "../$pkgname.license" "$pkgdir/usr/share/licenses/stk/LICENSE" }