void-packages/srcpkgs/libopenmpt/template
2020-12-12 03:17:12 -03:00

51 lines
1.6 KiB
Bash

# Template file for 'libopenmpt'
pkgname=libopenmpt
version=0.5.4
revision=1
wrksrc="libopenmpt-${version}+release.autotools"
build_style=gnu-configure
configure_args="$(vopt_with pulseaudio)
$(vopt_with sdl) $(vopt_with sdl2)
$(vopt_enable libopenmpt_modplug) $(vopt_enable libmodplug)"
hostmakedepends="pkg-config"
makedepends="zlib-devel mpg123-devel libogg-devel libvorbis-devel
portaudio-devel portaudio-cpp-devel libsndfile-devel libflac-devel
$(vopt_if pulseaudio pulseaudio-devel) $(vopt_if sdl2 SDL2-devel)
$(vopt_if sdl SDL-devel)"
short_desc="Cross-platform C & C++ library to decode tracked music files (modules)"
maintainer="a dinosaur <nick@a-dinosaur.com>"
license="BSD-3-Clause"
homepage="https://lib.openmpt.org/libopenmpt/"
distfiles="https://lib.openmpt.org/files/libopenmpt/src/libopenmpt-${version}+release.autotools.tar.gz"
checksum=f34d06b9daa7bca111625369e5bbc2e7c0e0e04737a439b0e6320811babcef40
conflicts="$(vopt_if libmodplug libmodplug)"
post_install() {
vlicense LICENSE
}
# Package build options
build_options="pulseaudio sdl2 sdl libopenmpt_modplug libmodplug"
build_options_default="pulseaudio"
vopt_conflict sdl2 sdl
libopenmpt-devel_package() {
depends="${sourcepkg}-${version}_${revision}"
short_desc+=" - development files"
pkg_install() {
vmove usr/share/doc/libopenmpt/examples
vmove usr/include
vmove usr/lib/pkgconfig
vmove "usr/lib/*.a"
vmove "usr/lib/*.so"
}
}
openmpt123_package() {
depends="${sourcepkg}-${version}_${revision}"
short_desc="Cross-platform command-line or terminal based module file player"
pkg_install() {
vmove usr/bin/openmpt123
vmove usr/share/man/man1/openmpt123.1
}
}