> Main purpose of this patch is documenting how to enable music in > OpenTTD. It also zaps a patch we don't need since we could provide > a configure script option instead. > > We could just hardcode dependcy on fluidsynth, but that involves > some trickery if you want to do it properly, since --with-midi-arg > does work with single arguments only. And changing dependencies > close to release isn't a good thing, either. > > This patch makes happy at least two polite Russians... okay?
Englishified version, thanks to bcallah@ for his input. -- WBR, Vadim Zhukov Index: Makefile =================================================================== RCS file: /cvs/ports/games/openttd/Makefile,v retrieving revision 1.36 diff -u -p -r1.36 Makefile --- Makefile 1 Jul 2014 02:09:27 -0000 1.36 +++ Makefile 26 Jul 2014 13:10:02 -0000 @@ -13,6 +13,7 @@ DISTFILES= ${DISTNAME}${EXTRACT_SUFX} \ opensfx-${SFX_V}.zip:1 \ openmsx-${MSX_V}.zip:2 DIST_SUBDIR= openttd +REVISION = 0 CATEGORIES= games @@ -53,6 +54,7 @@ CONFIGURE_ARGS+= --prefix-dir=${PREFIX} --with-zlib \ --without-allegro \ --without-libtimidity \ + --with-midi=/usr/bin/midiplay \ --CFLAGS_BUILD="${CFLAGS}" \ --disable-strip Index: patches/patch-src_music_extmidi_cpp =================================================================== RCS file: patches/patch-src_music_extmidi_cpp diff -N patches/patch-src_music_extmidi_cpp --- patches/patch-src_music_extmidi_cpp 25 Dec 2012 00:17:37 -0000 1.2 +++ /dev/null 1 Jan 1970 00:00:00 -0000 @@ -1,12 +0,0 @@ -$OpenBSD: patch-src_music_extmidi_cpp,v 1.2 2012/12/25 00:17:37 bentley Exp $ ---- src/music/extmidi.cpp.orig Sun Nov 18 01:08:34 2012 -+++ src/music/extmidi.cpp Sun Nov 18 01:08:38 2012 -@@ -27,7 +27,7 @@ - - #ifndef EXTERNAL_PLAYER - /** The default external midi player. */ --#define EXTERNAL_PLAYER "timidity" -+#define EXTERNAL_PLAYER "midiplay" - #endif - - /** Factory for the midi player that uses external players. */ Index: pkg/README =================================================================== RCS file: /cvs/ports/games/openttd/pkg/README,v retrieving revision 1.2 diff -u -p -r1.2 README --- pkg/README 2 Jun 2011 13:41:38 -0000 1.2 +++ pkg/README 26 Jul 2014 13:10:02 -0000 @@ -19,3 +19,13 @@ If you want the original Transport Tycoo contents of the gm/ folder from the Windows version of Transport Tycoon Deluxe to ${TRUEPREFIX}/share/openttd/gm/. The music from the DOS and original Transport Tycoon versions does not work. + +For music you need either a hardware or software synthesizer enabled +and running. If you don't have one (and thus hear no music), you +can install the "fluidsynth" and "generaluser-gs-soundfont" packages, +and run the following command prior starting OpenTTD: + + fluidsynth ${LOCALBASE}/share/generaluser-gs/GeneraUser_GS.sf2 + +You don't need to type anything at the fluidsynth shell prompt, just +start OpenTTD now.