void-packages/srcpkgs/stk/template

99 lines
2.5 KiB
Bash
Raw Normal View History

2020-04-14 13:01:55 +02:00
# Template file for 'stk'
pkgname=stk
version=4.6.1
revision=3
2020-04-14 13:01:55 +02:00
build_style=gnu-configure
configure_args="--with-alsa --with-jack RAWWAVE_PATH=/usr/share/stk/rawwaves/"
2020-04-14 13:01:55 +02:00
hostmakedepends="automake libtool pkg-config"
makedepends="alsa-lib-devel jack-devel"
depends="libstk-${version}_${revision} stk-data-${version}_${revision}"
2020-04-14 13:01:55 +02:00
short_desc="Synthesis ToolKit in C++"
maintainer="Jürgen Buchmüller <pullmoll@t-online.de>"
license="custom:MIT-like"
homepage="https://ccrma.stanford.edu/software/stk/"
distfiles="https://github.com/thestk/stk/archive/${version}.tar.gz>${pkgname}-${version}.tar.gz"
checksum=8e0c362dd82421bae8f3e789d238a1c27aeac1a2697d7830eb51abc90fc17281
pre_configure() {
NOCONFIGURE=1 autoreconf -fi
}
post_install() {
2020-04-14 13:37:54 +02:00
# Fix wrong 32 bit library install path
if [ -f "${DESTDIR}"/usr/usr/lib32/libstk.so ]; then
mv -v "${DESTDIR}"/usr/usr/lib32/* "${DESTDIR}"/usr/lib
fi
# Create a pkg-config file
2020-04-14 13:01:55 +02:00
vmkdir usr/lib/pkgconfig
sed ${FILESDIR}/stk.pc \
-e "s;@VERSION@;${version};" \
> ${DESTDIR}/usr/lib/pkgconfig/stk.pc
# Install binaries
vmkdir usr/libexec/stk
vinstall projects/demo/stk-demo 755 usr/libexec/stk
vinstall projects/effects/effects 755 usr/libexec/stk
vinstall projects/eguitar/eguitar 755 usr/libexec/stk
vinstall projects/ragamatic/ragamat 755 usr/libexec/stk
# Install examples
vmkdir usr/libexec/stk/examples
for f in play record audioprobe midiprobe duplex inetIn inetOut \
rtsine crtsine bethree controlbee three bees playsmf grains; do
if [ -x "projects/examples/$f" ]; then
vinstall projects/examples/$f 755 usr/libexec/stk/examples
fi
done
2020-04-14 13:01:55 +02:00
# Install examples data
vcopy projects/examples/midifiles usr/libexec/stk/examples
vcopy projects/examples/rawwaves usr/libexec/stk/examples
vcopy projects/examples/scores usr/libexec/stk/examples
# Install stk data
vmkdir usr/share/stk
vcopy rawwaves usr/share/stk
# Documentation
vdoc doc/README-Linux.txt
vdoc doc/SKINI.txt
vdoc doc/hierarchy.txt
vdoc doc/treesed.html
2020-04-14 13:01:55 +02:00
vlicense LICENSE
}
stk-data_package() {
short_desc+=" - data files"
archs=noarch
pkg_install() {
vmove usr/share/stk
}
}
2020-04-14 13:01:55 +02:00
stk-examples_package() {
short_desc+=" - examples"
depends="${sourcepkg}>=${version}_${revision}"
pkg_install() {
vmove usr/libexec/stk/examples
}
}
libstk_package() {
short_desc+=" - library"
pkg_install() {
vmove usr/lib/libstk-${version}.so
}
}
libstk-devel_package() {
short_desc+=" - development files"
depends="libstk-${version}_${revision} ${makedepends}"
pkg_install() {
vmove usr/include
vmove usr/lib/libstk.so
vmove usr/lib/pkgconfig
}
}