vp-build/srcpkgs/timidity/template

43 lines
1.6 KiB
Bash
Raw Permalink Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

# Template file for 'timidity'
pkgname=timidity
version=2.15.0
revision=1
wrksrc="TiMidity++-${version}"
build_style=gnu-configure
configure_args="--with-default-path=/etc/timidity
--enable-audio=alsa,oss,ao,vorbis,flac --enable-server
--enable-alsaseq=yes --enable-network
--enable-gtk --enable-ncurses"
hostmakedepends="pkg-config"
makedepends="alsa-lib-devel libvorbis-devel libao-devel libflac-devel
libX11-devel gtk+-devel ncurses-devel"
short_desc="MIDI to WAVE converter and player"
maintainer="David <kalichakra@zoho.com>"
license="GPL-2.0-or-later"
homepage="http://timidity.sourceforge.net"
distfiles="${SOURCEFORGE_SITE}/timidity/TiMidity++-${version}.tar.xz"
checksum=9eaf4fadb0e19eb8e35cd4ac16142d604c589e43d0e8798237333697e6381d39
case "$XBPS_TARGET_MACHINE" in
*-musl) broken="uses alsa's pcm_old.h, which depends on symbol versioning to work";;
esac
if [ "$CROSS_BUILD" ]; then
# check for va_copy runs test program; assume no for target
configure_args+=" lib_cv_va_copy=no lib_cv___va_copy=no lib_cv_va_val_copy=no"
pre_configure() {
# configure assumes OggFLAC is available on target and uses default values
sed -i -e 's|no_libOggFLAC=""|no_libOggFLAC="yes"|' configure
}
pre_build() {
# build calcnewt with host gcc (calcnewt generates newton_table.c)
gcc -o timidity/calcnewt -lm timidity/calcnewt.c
# remove rule for calcnewt from Makefile and make
# newton_table.c not depend on removed rule
sed -i -e '/calcnewt$(EXEEXT): $(calcnewt_OBJECTS) $(calcnewt_DEPENDENCIES)/,+2d' \
-e 's|\(newton_table.c:\) calcnewt$(EXEEXT)|\1|' timidity/Makefile
}
fi