summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAlexis Ballier <aballier@gentoo.org>2007-03-25 21:47:48 +0000
committerAlexis Ballier <aballier@gentoo.org>2007-03-25 21:47:48 +0000
commitf61e1053ebf7c6c1c2b57081a93b6071aab92411 (patch)
tree0f4649d6b859009b5e14f122db59d4c9da2131af /media-sound/timidity++
parentia64 stable wrt bug 155112 (diff)
downloadgentoo-2-f61e1053ebf7c6c1c2b57081a93b6071aab92411.tar.gz
gentoo-2-f61e1053ebf7c6c1c2b57081a93b6071aab92411.tar.bz2
gentoo-2-f61e1053ebf7c6c1c2b57081a93b6071aab92411.zip
Revbump in ~arch for flac 1.1.3 compatibility
(Portage version: 2.1.2.2)
Diffstat (limited to 'media-sound/timidity++')
-rw-r--r--media-sound/timidity++/ChangeLog8
-rw-r--r--media-sound/timidity++/files/digest-timidity++-2.13.2-r46
-rw-r--r--media-sound/timidity++/files/timidity++-2.13.2-flac113.patch281
-rw-r--r--media-sound/timidity++/timidity++-2.13.2-r4.ebuild161
4 files changed, 455 insertions, 1 deletions
diff --git a/media-sound/timidity++/ChangeLog b/media-sound/timidity++/ChangeLog
index 5ef5f1e0b134..405f34b56fcc 100644
--- a/media-sound/timidity++/ChangeLog
+++ b/media-sound/timidity++/ChangeLog
@@ -1,6 +1,12 @@
# ChangeLog for media-sound/timidity++
# Copyright 2002-2007 Gentoo Foundation; Distributed under the GPL v2
-# $Header: /var/cvsroot/gentoo-x86/media-sound/timidity++/ChangeLog,v 1.83 2007/02/24 15:22:18 jer Exp $
+# $Header: /var/cvsroot/gentoo-x86/media-sound/timidity++/ChangeLog,v 1.84 2007/03/25 21:47:48 aballier Exp $
+
+*timidity++-2.13.2-r4 (25 Mar 2007)
+
+ 25 Mar 2007; Alexis Ballier <aballier@gentoo.org>
+ +files/timidity++-2.13.2-flac113.patch, +timidity++-2.13.2-r4.ebuild:
+ Revbump in ~arch for flac 1.1.3 compatibility
24 Feb 2007; Jeroen Roovers <jer@gentoo.org> timidity++-2.13.2-r3.ebuild:
Stable for HPPA (bug #156160).
diff --git a/media-sound/timidity++/files/digest-timidity++-2.13.2-r4 b/media-sound/timidity++/files/digest-timidity++-2.13.2-r4
new file mode 100644
index 000000000000..7a95c8bb2fb6
--- /dev/null
+++ b/media-sound/timidity++/files/digest-timidity++-2.13.2-r4
@@ -0,0 +1,6 @@
+MD5 a82ceeb2245e22f4de2b41da21eaee32 TiMidity++-2.13.2.tar.bz2 1581230
+RMD160 0156221846a88abef9312700a050972d85084fd8 TiMidity++-2.13.2.tar.bz2 1581230
+SHA256 0a8524b789b57eaf944c3d9bce32c21a4e893016b22a02a24cd0a4c6afee7260 TiMidity++-2.13.2.tar.bz2 1581230
+MD5 31bdaea612f18e2c3d45a8a73ab44c81 timidity++-2.13.2-exiterror.patch 21406
+RMD160 6b73552e18580422ca4471f12142440a4f3760a9 timidity++-2.13.2-exiterror.patch 21406
+SHA256 ccf1a3678beff5cd143bec07b64ca35620b8eac98b093898c072459051752b77 timidity++-2.13.2-exiterror.patch 21406
diff --git a/media-sound/timidity++/files/timidity++-2.13.2-flac113.patch b/media-sound/timidity++/files/timidity++-2.13.2-flac113.patch
new file mode 100644
index 000000000000..e7f9d4bc55bb
--- /dev/null
+++ b/media-sound/timidity++/files/timidity++-2.13.2-flac113.patch
@@ -0,0 +1,281 @@
+Index: TiMidity++-2.13.2/timidity/flac_a.c
+===================================================================
+--- TiMidity++-2.13.2.orig/timidity/flac_a.c
++++ TiMidity++-2.13.2/timidity/flac_a.c
+@@ -45,6 +45,11 @@
+ #endif
+
+ #include <FLAC/all.h>
++#if !defined(FLAC_API_VERSION_CURRENT) || FLAC_API_VERSION_CURRENT < 8
++#define LEGACY_FLAC
++#else
++#undef LEGACY_FLAC
++#endif
+ #ifdef AU_OGGFLAC
+ #include <OggFLAC/stream_encoder.h>
+ #endif
+@@ -100,7 +105,11 @@ typedef struct {
+ unsigned long out_bytes;
+ union {
+ FLAC__StreamEncoderState flac;
++#ifdef LEGACY_FLAC
+ FLAC__SeekableStreamEncoderState s_flac;
++#else
++ FLAC__StreamEncoderState s_flac;
++#endif
+ #ifdef AU_OGGFLAC
+ OggFLAC__StreamEncoderState ogg;
+ #endif
+@@ -108,7 +117,11 @@ typedef struct {
+ union {
+ union {
+ FLAC__StreamEncoder *stream;
++#ifdef LEGACY_FLAC
+ FLAC__SeekableStreamEncoder *s_stream;
++#else
++ FLAC__StreamEncoder *s_stream;
++#endif
+ } flac;
+ #ifdef AU_OGGFLAC
+ union {
+@@ -174,11 +187,19 @@ static void flac_stream_encoder_metadata
+ const FLAC__StreamMetadata *metadata,
+ void *client_data);
+ static FLAC__StreamEncoderWriteStatus
++#ifdef LEGACY_FLAC
+ flac_seekable_stream_encoder_write_callback(const FLAC__SeekableStreamEncoder *encoder,
++#else
++flac_seekable_stream_encoder_write_callback(const FLAC__StreamEncoder *encoder,
++#endif
+ const FLAC__byte buffer[],
+ unsigned bytes, unsigned samples,
+ unsigned current_frame, void *client_data);
++#ifdef LEGACY_FLAC
+ static void flac_seekable_stream_encoder_metadata_callback(const FLAC__SeekableStreamEncoder *encoder,
++#else
++static void flac_seekable_stream_encoder_metadata_callback(const FLAC__StreamEncoder *encoder,
++#endif
+ const FLAC__StreamMetadata *metadata,
+ void *client_data);
+
+@@ -306,8 +327,13 @@ static int flac_session_close()
+ #endif /* AU_OGGFLAC */
+ if (flac_options.seekable) {
+ if (ctx->encoder.flac.s_stream) {
++#ifdef LEGACY_FLAC
+ FLAC__seekable_stream_encoder_finish(ctx->encoder.flac.s_stream);
+ FLAC__seekable_stream_encoder_delete(ctx->encoder.flac.s_stream);
++#else
++ FLAC__stream_encoder_finish(ctx->encoder.flac.s_stream);
++ FLAC__stream_encoder_delete(ctx->encoder.flac.s_stream);
++#endif
+ }
+ }
+ else
+@@ -435,17 +461,29 @@ static int flac_output_open(const char *
+ else
+ #endif /* AU_OGGFLAC */
+ if (flac_options.seekable) {
++#ifdef LEGACY_FLAC
+ if ((ctx->encoder.flac.s_stream = FLAC__seekable_stream_encoder_new()) == NULL) {
++#else
++ if ((ctx->encoder.flac.s_stream = FLAC__stream_encoder_new()) == NULL) {
++#endif
+ ctl->cmsg(CMSG_ERROR, VERB_NORMAL, "cannot create FLAC stream");
+ flac_session_close();
+ return -1;
+ }
+
++#ifdef LEGACY_FLAC
+ FLAC__seekable_stream_encoder_set_channels(ctx->encoder.flac.s_stream, nch);
+ /* 16bps only */
+ FLAC__seekable_stream_encoder_set_bits_per_sample(ctx->encoder.flac.s_stream, 16);
+
+ FLAC__seekable_stream_encoder_set_verify(ctx->encoder.flac.s_stream, flac_options.verify);
++#else
++ FLAC__stream_encoder_set_channels(ctx->encoder.flac.s_stream, nch);
++ /* 16bps only */
++ FLAC__stream_encoder_set_bits_per_sample(ctx->encoder.flac.s_stream, 16);
++
++ FLAC__stream_encoder_set_verify(ctx->encoder.flac.s_stream, flac_options.verify);
++#endif
+
+ if (!FLAC__format_sample_rate_is_valid(dpm.rate)) {
+ ctl->cmsg(CMSG_ERROR, VERB_NORMAL, "invalid sampling rate %d",
+@@ -453,27 +491,54 @@ static int flac_output_open(const char *
+ flac_session_close();
+ return -1;
+ }
++#ifdef LEGACY_FLAC
+ FLAC__seekable_stream_encoder_set_sample_rate(ctx->encoder.flac.s_stream, dpm.rate);
+
+ FLAC__seekable_stream_encoder_set_qlp_coeff_precision(ctx->encoder.flac.s_stream, flac_options.qlp_coeff_precision);
+ /* expensive! */
+ FLAC__seekable_stream_encoder_set_do_qlp_coeff_prec_search(ctx->encoder.flac.s_stream, flac_options.qlp_coeff_precision_search);
++#else
++ FLAC__stream_encoder_set_sample_rate(ctx->encoder.flac.s_stream, dpm.rate);
++
++ FLAC__stream_encoder_set_qlp_coeff_precision(ctx->encoder.flac.s_stream, flac_options.qlp_coeff_precision);
++ /* expensive! */
++ FLAC__stream_encoder_set_do_qlp_coeff_prec_search(ctx->encoder.flac.s_stream, flac_options.qlp_coeff_precision_search);
++#endif
++
+
+ if (nch == 2) {
++#ifdef LEGACY_FLAC
+ FLAC__seekable_stream_encoder_set_do_mid_side_stereo(ctx->encoder.flac.s_stream, flac_options.mid_side);
+ FLAC__seekable_stream_encoder_set_loose_mid_side_stereo(ctx->encoder.flac.s_stream, flac_options.adaptive_mid_side);
++#else
++ FLAC__stream_encoder_set_do_mid_side_stereo(ctx->encoder.flac.s_stream, flac_options.mid_side);
++ FLAC__stream_encoder_set_loose_mid_side_stereo(ctx->encoder.flac.s_stream, flac_options.adaptive_mid_side);
++#endif
+ }
+
++#ifdef LEGACY_FLAC
+ FLAC__seekable_stream_encoder_set_max_lpc_order(ctx->encoder.flac.s_stream, flac_options.max_lpc_order);
+ FLAC__seekable_stream_encoder_set_min_residual_partition_order(ctx->encoder.flac.s_stream, flac_options.min_residual_partition_order);
+ FLAC__seekable_stream_encoder_set_max_residual_partition_order(ctx->encoder.flac.s_stream, flac_options.max_residual_partition_order);
+
+ FLAC__seekable_stream_encoder_set_blocksize(ctx->encoder.flac.s_stream, flac_options.blocksize);
+ FLAC__seekable_stream_encoder_set_client_data(ctx->encoder.flac.s_stream, ctx);
++#else
++ FLAC__stream_encoder_set_max_lpc_order(ctx->encoder.flac.s_stream, flac_options.max_lpc_order);
++ FLAC__stream_encoder_set_min_residual_partition_order(ctx->encoder.flac.s_stream, flac_options.min_residual_partition_order);
++ FLAC__stream_encoder_set_max_residual_partition_order(ctx->encoder.flac.s_stream, flac_options.max_residual_partition_order);
++
++ FLAC__stream_encoder_set_blocksize(ctx->encoder.flac.s_stream, flac_options.blocksize);
++#endif
+
+ if (0 < num_metadata)
++#ifdef LEGACY_FLAC
+ FLAC__seekable_stream_encoder_set_metadata(ctx->encoder.flac.s_stream, metadata, num_metadata);
++#else
++ FLAC__stream_encoder_set_metadata(ctx->encoder.flac.s_stream, metadata, num_metadata);
++#endif
+
++#ifdef LEGACY_FLAC
+ /* set callback */
+ /* FLAC__seekable_stream_encoder_set_metadata_callback(ctx->encoder.flac.s_stream, flac_seekable_stream_encoder_metadata_callback); /* */
+ #ifndef __BORLANDC__
+@@ -483,8 +548,17 @@ static int flac_output_open(const char *
+
+ ctx->state.s_flac = FLAC__seekable_stream_encoder_init(ctx->encoder.flac.s_stream);
+ if (ctx->state.s_flac != FLAC__SEEKABLE_STREAM_ENCODER_OK) {
++#else
++
++ ctx->state.s_flac = FLAC__stream_encoder_init_stream(ctx->encoder.flac.s_stream, flac_seekable_stream_encoder_write_callback, NULL, NULL, flac_seekable_stream_encoder_metadata_callback, ctx);
++ if (ctx->state.s_flac != FLAC__STREAM_ENCODER_OK) {
++#endif
+ ctl->cmsg(CMSG_ERROR, VERB_NORMAL, "cannot create FLAC state (%s)",
++#ifdef LEGACY_FLAC
+ FLAC__SeekableStreamEncoderStateString[ctx->state.s_flac]);
++#else
++ FLAC__StreamEncoderStateString[ctx->state.s_flac]);
++#endif
+ flac_session_close();
+ return -1;
+ }
+@@ -525,16 +599,22 @@ static int flac_output_open(const char *
+ FLAC__stream_encoder_set_max_residual_partition_order(ctx->encoder.flac.stream, flac_options.max_residual_partition_order);
+
+ FLAC__stream_encoder_set_blocksize(ctx->encoder.flac.stream, flac_options.blocksize);
++#ifdef LEGACY_FLAC
+ FLAC__stream_encoder_set_client_data(ctx->encoder.flac.stream, ctx);
++#endif
+
+ if (0 < num_metadata)
+ FLAC__stream_encoder_set_metadata(ctx->encoder.flac.stream, metadata, num_metadata);
+
++#ifdef LEGACY_FLAC
+ /* set callback */
+ FLAC__stream_encoder_set_metadata_callback(ctx->encoder.flac.stream, flac_stream_encoder_metadata_callback);
+ FLAC__stream_encoder_set_write_callback(ctx->encoder.flac.stream, flac_stream_encoder_write_callback);
+
+ ctx->state.flac = FLAC__stream_encoder_init(ctx->encoder.flac.stream);
++#else
++ ctx->state.flac = FLAC__stream_encoder_init_stream(ctx->encoder.flac.stream, flac_stream_encoder_write_callback, NULL, NULL, flac_stream_encoder_metadata_callback, ctx);
++#endif
+ if (ctx->state.flac != FLAC__STREAM_ENCODER_OK) {
+ ctl->cmsg(CMSG_ERROR, VERB_NORMAL, "cannot create FLAC state (%s)",
+ FLAC__StreamEncoderStateString[ctx->state.flac]);
+@@ -676,7 +756,11 @@ static void flac_stream_encoder_metadata
+ {
+ }
+ static FLAC__StreamEncoderWriteStatus
++#ifdef LEGACY_FLAC
+ flac_seekable_stream_encoder_write_callback(const FLAC__SeekableStreamEncoder *encoder,
++#else
++flac_seekable_stream_encoder_write_callback(const FLAC__StreamEncoder *encoder,
++#endif
+ const FLAC__byte buffer[],
+ unsigned bytes, unsigned samples,
+ unsigned current_frame, void *client_data)
+@@ -690,7 +774,11 @@ flac_seekable_stream_encoder_write_callb
+ else
+ return FLAC__STREAM_ENCODER_WRITE_STATUS_FATAL_ERROR;
+ }
++#ifdef LEGACY_FLAC
+ static void flac_seekable_stream_encoder_metadata_callback(const FLAC__SeekableStreamEncoder *encoder,
++#else
++static void flac_seekable_stream_encoder_metadata_callback(const FLAC__StreamEncoder *encoder,
++#endif
+ const FLAC__StreamMetadata *metadata,
+ void *client_data)
+ {
+@@ -747,22 +835,38 @@ static int output_data(char *buf, int32
+ else
+ #endif /* AU_OGGFLAC */
+ if (flac_options.seekable) {
++#ifdef LEGACY_FLAC
+ ctx->state.s_flac = FLAC__seekable_stream_encoder_get_state(ctx->encoder.flac.s_stream);
++#else
++ ctx->state.s_flac = FLAC__stream_encoder_get_state(ctx->encoder.flac.s_stream);
++#endif
+ if (ctx->state.s_flac != FLAC__STREAM_ENCODER_OK) {
+ if (ctx->state.s_flac == FLAC__STREAM_ENCODER_VERIFY_DECODER_ERROR |
+ FLAC__STREAM_ENCODER_VERIFY_MISMATCH_IN_AUDIO_DATA) {
+ ctl->cmsg(CMSG_ERROR, VERB_NORMAL, "FLAC stream verify error (%s)",
++#ifdef LEGACY_FLAC
+ FLAC__SeekableStreamDecoderStateString[FLAC__seekable_stream_encoder_get_verify_decoder_state(ctx->encoder.flac.s_stream)]);
++#else
++ FLAC__StreamDecoderStateString[FLAC__stream_encoder_get_verify_decoder_state(ctx->encoder.flac.s_stream)]);
++#endif
+ }
+ else {
+ ctl->cmsg(CMSG_ERROR, VERB_NORMAL, "cannot encode FLAC stream (%s)",
++#ifdef LEGACY_FLAC
+ FLAC__SeekableStreamEncoderStateString[ctx->state.s_flac]);
++#else
++ FLAC__StreamEncoderStateString[ctx->state.s_flac]);
++#endif
+ }
+ flac_session_close();
+ return -1;
+ }
+
++#ifdef LEGACY_FLAC
+ if (!FLAC__seekable_stream_encoder_process_interleaved(ctx->encoder.flac.s_stream, oggbuf,
++#else
++ if (!FLAC__stream_encoder_process_interleaved(ctx->encoder.flac.s_stream, oggbuf,
++#endif
+ nbytes / nch / 2 )) {
+ ctl->cmsg(CMSG_ERROR, VERB_NORMAL, "cannot encode FLAC stream");
+ flac_session_close();
+@@ -823,9 +927,17 @@ static void close_output(void)
+ else
+ #endif /* AU_OGGFLAC */
+ if (flac_options.seekable) {
++#ifdef LEGACY_FLAC
+ if ((ctx->state.s_flac = FLAC__seekable_stream_encoder_get_state(ctx->encoder.flac.s_stream)) != FLAC__SEEKABLE_STREAM_ENCODER_OK) {
++#else
++ if ((ctx->state.s_flac = FLAC__stream_encoder_get_state(ctx->encoder.flac.s_stream)) != FLAC__STREAM_ENCODER_OK) {
++#endif
+ ctl->cmsg(CMSG_ERROR, VERB_NORMAL, "FLAC stream encoder is invalid (%s)",
++#ifdef LEGACY_FLAC
+ FLAC__SeekableStreamEncoderStateString[ctx->state.s_flac]);
++#else
++ FLAC__StreamEncoderStateString[ctx->state.s_flac]);
++#endif
+ /* fall through */
+ }
+ }
diff --git a/media-sound/timidity++/timidity++-2.13.2-r4.ebuild b/media-sound/timidity++/timidity++-2.13.2-r4.ebuild
new file mode 100644
index 000000000000..6cf580251a49
--- /dev/null
+++ b/media-sound/timidity++/timidity++-2.13.2-r4.ebuild
@@ -0,0 +1,161 @@
+# Copyright 1999-2007 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Header: /var/cvsroot/gentoo-x86/media-sound/timidity++/timidity++-2.13.2-r4.ebuild,v 1.1 2007/03/25 21:47:48 aballier Exp $
+
+inherit eutils
+
+MY_PV=${PV/_/-}
+MY_P=TiMidity++-${MY_PV}
+S=${WORKDIR}/${MY_P}
+
+DESCRIPTION="A handy MIDI to WAV converter with OSS and ALSA output support"
+HOMEPAGE="http://timidity.sourceforge.net/"
+SRC_URI="mirror://sourceforge/timidity/${MY_P}.tar.bz2 mirror://gentoo/${P}-exiterror.patch"
+
+LICENSE="GPL-2"
+SLOT="0"
+KEYWORDS="~amd64 ~hppa ~ppc ~ppc64 ~sparc ~x86 ~x86-fbsd"
+IUSE="oss nas esd motif X gtk gtk vorbis tk slang alsa arts jack portaudio emacs ao speex flac ncurses"
+
+DEPEND="ncurses? ( >=sys-libs/ncurses-5.0 )
+ gtk? ( >=x11-libs/gtk+-2.0 )
+ tk? ( >=dev-lang/tk-8.1 )
+ motif? ( virtual/motif )
+ esd? ( >=media-sound/esound-0.2.22 )
+ nas? ( >=media-libs/nas-1.4 )
+ alsa? ( media-libs/alsa-lib )
+ slang? ( =sys-libs/slang-1.4* )
+ arts? ( kde-base/arts )
+ jack? ( media-sound/jack-audio-connection-kit )
+ portaudio? ( media-libs/portaudio )
+ vorbis? ( >=media-libs/libvorbis-1.0_beta4 )
+ flac? ( >=media-libs/flac-1.1.2 )
+ speex? ( >=media-libs/speex-1.1.5 )
+ ao? ( >=media-libs/libao-0.8.5 )"
+
+RDEPEND="${RDEPEND}
+ app-admin/eselect-timidity
+ emacs? ( virtual/emacs )"
+
+PDEPEND="|| ( media-sound/timidity-eawpatches media-sound/timidity-shompatches media-sound/timidity-freepats )"
+
+pkg_setup() {
+ if use alsa && ! built_with_use --missing true media-libs/alsa-lib midi; then
+ eerror ""
+ eerror "To be able to build TiMidity++ with ALSA support you need"
+ eerror "to have built media-libs/alsa-lib with midi USE flag."
+ die "Missing midi USE flag on media-libs/alsa-lib"
+ fi
+}
+
+src_unpack() {
+ unpack ${A}
+ cd "${S}"
+ epatch "${DISTDIR}/${P}-exiterror.patch"
+ epatch "${FILESDIR}/${P}-gtk26.patch"
+ epatch "${FILESDIR}/${P}-gcc4.patch"
+ epatch "${FILESDIR}/${P}-flac.patch"
+ epatch "${FILESDIR}/${P}-flac113.patch"
+
+ # fix header location of speex
+ sed -i -e "s:#include <speex:#include <speex/speex:g" configure* timidity/speex_a.c
+}
+
+src_compile() {
+ local myconf
+ local audios
+
+ use flac && audios="${audios},flac"
+ use speex && audios="${audios},speex"
+ use vorbis && audios="${audios},vorbis"
+
+ use oss && audios="${audios},oss"
+ use esd && audios="${audios},esd"
+ use arts && audios="${audios},arts"
+ use jack && audios="${audios},jack"
+ use portaudio && use !ppc && audios="${audios},portaudio"
+ use ao && audios="${audios},ao"
+
+ if use nas; then
+ audios="${audios},nas"
+ myconf="${myconf} --with-nas-library=/usr/$(get_libdir)/libaudio.so --with-x"
+ use X || ewarn "Basic X11 support will be enabled because required by nas."
+ fi
+
+ if use alsa; then
+ audios="${audios},alsa"
+ myconf="${myconf} --with-default-output=alsa --enable-alsaseq"
+ fi
+
+ # We disable motif by default and then only enable it if it's requested.
+ if use motif; then
+ myconf="${myconf} --enable-motif --with-x"
+ use X || ewarn "Basic X11 support will be enabled because required by motif."
+ fi
+
+ econf \
+ --localstatedir=/var/state/timidity++ \
+ --with-elf \
+ --enable-audio=${audios} \
+ --enable-server \
+ --enable-network \
+ --enable-dynamic \
+ --enable-vt100 \
+ --enable-spline=cubic \
+ $(use_enable emacs) \
+ $(use_enable slang) \
+ $(use_enable ncurses) \
+ $(use_with X x) \
+ $(use_enable X spectrogram) \
+ $(use_enable X wrd) \
+ $(use_enable X xskin) \
+ $(use_enable X xaw) \
+ $(use_enable gtk) \
+ $(use_enable tk tcltk) \
+ --disable-motif \
+ ${myconf} || die
+
+ emake || die
+}
+
+src_install() {
+ make DESTDIR="${D}" install || die
+
+ dodoc AUTHORS ChangeLog*
+ dodoc NEWS README* "${FILESDIR}/timidity.cfg"
+
+ # these are only for the ALSA sequencer mode
+ if use alsa; then
+ newconfd "${FILESDIR}/conf.d.timidity" timidity
+ newinitd "${FILESDIR}/init.d.timidity" timidity
+ fi
+
+ insinto /etc
+ newins "${FILESDIR}/timidity.cfg-r1" timidity.cfg
+
+ dodir /usr/share/timidity
+ dosym /etc/timidity.cfg /usr/share/timidity/timidity.cfg
+
+ if use emacs ; then
+ dosed 's:/usr/local/bin/timidity:/usr/bin/timidity:g' /usr/share/emacs/site-lisp/timidity.el
+ else
+ rm "${D}/timidity.el"
+ fi
+}
+
+pkg_postinst() {
+ elog "A timidity config file has been installed in /etc/timidity.cfg."
+ elog "Do not edit this file as it will interfere with the eselect timidity tool."
+ elog "The tool 'eselect timidity' can be used to switch between installed patchsets."
+
+ if use alsa; then
+ elog "An init script for the alsa timidity sequencer has been installed."
+ elog "If you wish to use the timidity virtual sequencer, edit /etc/conf.d/timidity"
+ elog "and run 'rc-update add timidity <runlevel> && /etc/init.d/timidity start'"
+ fi
+
+ if use sparc; then
+ ewarn "sparc support is experimental. oss, alsa, esd, and portaudio do not work."
+ ewarn "-Ow (save to wave file) does..."
+ fi
+}