Skip to content

Instantly share code, notes, and snippets.

@cocreature
Last active December 31, 2015 07:59
Show Gist options
  • Save cocreature/7957787 to your computer and use it in GitHub Desktop.
Save cocreature/7957787 to your computer and use it in GitHub Desktop.
pkgbuild zynaddsubfx-git
# Maintainer : SpepS <dreamspepser at yahoo dot it>
pkgname=zynaddsubfx-git
_pkgname=zynaddsubfx
pkgver=2.4.1.r364.g697e46a
pkgrel=1
pkgdesc="A powerful realtime, multi-timbral software synthesizer."
arch=('i686' 'x86_64')
url="http://zynaddsubfx.sourceforge.net"
license=('GPL')
depends=('fltk' 'fftw' 'portaudio' 'lash' 'mxml')
makedepends=('git' 'cmake' 'dssi')
optdepends=('dssi: dssi plugin')
provides=("$_pkgname")
conflicts=("$_pkgname")
options=('!emptydirs')
install="$pkgname.install"
source=("$pkgname"::"git://git.code.sf.net/p/$_pkgname/code"
"http://zynaddsubfx.sourceforge.net/doc/instruments/unsortedzynaddsubfxParameters_20131122.zip"
"http://zynaddsubfx.sourceforge.net/doc/instruments/banks20090520.zip"
"http://rekkerd.org/bin/presets/folderol_zynaddsubfx_Collection.zip"
"$_pkgname-jack.desktop"
"$_pkgname-alsa.desktop"
"$_pkgname.svg")
md5sums=('SKIP'
'f282369eebc5cc7a7b242424177b9369'
'7d7974e877b818fb562cc870d5886fc5'
'271ca88e262d3d3378f8d695a7151d1b'
'137baa3407ca0a9ce3d7f4644723978f'
'9825fcb4efc641ce1806d58cf1389aa9'
'6f7e9c3ce3947088a10c99c46a65431f')
pkgver() {
cd "$srcdir/$pkgname"
git describe --long | sed -E 's/([^-]*-g)/r\1/;s/-/./g'
}
_gitroot="git://$_p.git.sourceforge.net/gitroot/$_p/$_p"
_gitname="$_p"
build() {
cd "$srcdir/$pkgname"
# install dssi plugin in /usr/lib
sed -i 's/lib64/lib/' src/CMakeLists.txt
mkdir build && cd build
cmake .. -DGuiModule=ntk -DCMAKE_INSTALL_PREFIX=/usr
make
# build external programs
cd ../ExternalPrograms/Spliter && make
cd ../Controller && make
}
package() {
cd "$srcdir/$pkgname"
mkdir instruments/banks
cd "$srcdir/$pkgname/build"
make DESTDIR="$pkgdir/" install
# external programs
install -Dm755 ../ExternalPrograms/Spliter/spliter \
"$pkgdir/usr/bin/spliter"
install -Dm755 ../ExternalPrograms/Controller/controller \
"$pkgdir/usr/bin/controller"
# spliter doc
install -Dm644 ../ExternalPrograms/Spliter/readme.txt \
"$pkgdir/usr/share/doc/$_p/SPLITER.txt"
# icon and desktop file
install -Dm644 "$srcdir/$_pkgname-jack.desktop" \
"$pkgdir/usr/share/applications/$_pkgname-jack.desktop"
install -Dm644 "$srcdir/$_pkgname-alsa.desktop" \
"$pkgdir/usr/share/applications/$_pkgname-alsa.desktop"
install -Dm644 "$srcdir/$_pkgname.svg" \
"$pkgdir/usr/share/pixmaps/$_pkgname.svg"
# banks
install -d "$pkgdir/usr/share/$_pkgname/"
cp -a "$srcdir/banks20090520/"* "$pkgdir/usr/share/$_pkgname/banks"
cp -a "$srcdir/unsortedzynaddsubfxParameters_20131122" \
"$pkgdir/usr/share/$_pkgname/banks/Experimental"
cp -a "$srcdir/Collection" \
"$pkgdir/usr/share/$_pkgname/banks"
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment