1 ======================================================================
2 TiMidity++ Installation guide
7 version 2.13.0 or later
8 ======================================================================
10 This document describes how to install TiMidity++ for your UNIX-like
13 You can configure and make timidity.exe on the Cygwin environment of
14 Windows 95/98/Me/NT/2000/XP/2003. If you are in Windows, install
15 Cygwin (or mingw) if you do not have them.
17 Today's Macintosh has FreeBSD userland, so things described here would
18 fly. Methods for older Macintosh ("Classic") are not described here.
20 ======================================================================
22 ======================================================================
24 TiMidity++ uses GNU autotools to build. So the simplest way to
25 compile this package is:
27 1. "cd" to the directory containing TiMidity++'s source code and type
28 "./configure" to configure the package for your system. If you are
29 using csh on an old version of System V, you might need to type
30 "/bin/sh configure" instead to prevent csh from trying to execute
31 configure itself. Running configure takes a while. While running,
32 it prints some messages telling which features it is checking for.
33 2. Type "make" to compile the package.
34 NOTE: this make method requires GNU make. So if your system has it
35 as gamke, type "gmake" instead.
36 3. Type "make install" to install the programs and any data files and
39 ======================================================================
41 ======================================================================
43 The full installation process is:
46 2. edit common.makefile, Makefile, timidity.h if necessery
51 Each processes are explained in following sections. Note that % is
54 ======================================================================
56 ======================================================================
58 First, execute the following command:
60 % /bin/sh configure --help
62 Many options of configure will be displayed. Most of them, such as
63 --help, --prefix=PREFIX, and so on are the regular ones. They exisits
64 on most package that uses autoconf and you do not have to worry about
67 There also exists some options that is typical to TiMidity++. Main of
68 these are the following:
71 Enables debug. Things will be compiled with debugging methods/
75 TiMidity++ uses X by default. So you must specify this option to
76 prevent linker from linking X libraries.
78 --enable-audio[=audio_list]
79 Enables TiMidity++ to play MIDI files. If --enable-audio=no,
80 TiMidity++ acts as a MIDI-to-WAVE converter.
82 You can specify one or more audio-device listed below.
84 * default: Automatically select audio device.
86 * sun: SunOS /dev/audio
87 * hpux: hp-ux /dev/audio
88 * irix: IRIX audio library
90 * sb_dsp: BSD/OS 2.0 /dev/sb_dsp
92 * darwin: darwin(Mac OS X)'s CoreAudio frameowrk
93 * alsa: ALSA pcm device
94 * alib: hp-ux network audio (Alib)
96 * portaudio: PortAudio
101 * gogo: mp3 Gogo-No-Coder (Windows only)
103 --enable-interface[=interface_list]
104 --enable-dynamic[=interface_list]
105 Specify which interface to use. If you use --enable-dynamic instead
106 of --enable-interface, the interfaces specified will be linked
107 dynamically and the binary size would become a bit smaller.
109 You can select one or more interfaces listed below.
111 * ncurses: ncurses interface.
112 * slang: S-Lang interface.
113 * motif: Motif interface. Motif interface also works under Lestiff.
114 * tcltk: Tcl/Tk interface.
115 * emacs: Emacs front-end. Type M-x timidity to invoke.
116 * vt100: The full-screen interface using vt100 terminal control codes.
117 * xaw: X Athena Widget interface.
118 * xskin: X skin interface.
119 * gtk: GTK+ interface.
120 * w32gui: Build as Windows GUI binary.
121 * winsyn: Build as TiMidity++ Windows Synthesizer server.
122 * alsaseq: Build as ALSA sequencer client.
125 --enable-interface=INTERFACE1,INTERFACE2,...
127 --enable-INTERFACE1=yes --enable-INTERFACE2=yes ...
128 and for the same way,
129 --enable-dynamic=INTERFACE1,INTERFACE2,...
131 --enable-INTERFACE1=dynamic --enable-INTERFACE2=dynamic ...
134 Enables network support. This will allow TiMidity++ to open a MIDI
135 file via network. You can specify the location of MIDI files by
136 http://foo.com.tw/bar/baz.mid - like format.
139 With this option specified, TiMidity++ can open a window on X and
140 show sound-spectrogram there.
143 WRD is a Japanese local lyric-contents format. This option enables
146 * Environment variables and flags to pass to configure
148 Some MIDI files eat too much CPU power. If you choose correct
149 optimizing method, TiMidity++ can play such MIDI files smoothly.
151 You can tell configure which optimizing method to use by following
152 environmental variables:
155 the C compiler command e.g. "/usr/bin/gcc"
158 flags to pass to ${CC} e.g. "-O2 -pipe"
161 flags to pass to linker e.g. "-L/usr/gnu/lib"
164 flags to pass to preprocessor e.g. "-traditional-cpp"
166 Your compiler may have many optimization flags. For example, in case
167 of ultrasparc/gcc, you can specify:
169 % env CFLAGS='-O3 -Wall -mv8 -funroll-all-loops -fomit-frame-pointer \
170 -mcpu=ultrasparc' /bin/sh configure [configure-options]...
172 and the binary will (hopefully) run faster.
174 ======================================================================
176 ======================================================================
178 If make fails, or if you want to change some parameters, edit
179 common.makefile, Makefile, or timidity.h manually.
181 * Parameters in timidity.h
183 There are some options that are hard-coded into timidity binary. They
184 are # define-ed in timidity.h. You have to change things there if you
185 want to change these flags.
189 Edit CONFIG_FILE to your convenience. By default,
191 #define CONFIG_FILE DEFAULT_PATH "/timidity.cfg"
193 are recommended. DEFAULT_PATH is the same as TIMID_DIR in Makefile.
195 If you want to place it to another path, specify as the following:
197 #define CONFIG_FILE "/etc/timidity.cfg"
201 The file extractor (please ignore in Windows). By default:
203 #define DECOMPRESSOR_LIST { \
204 ".gz", "gunzip -c %s", \
205 ".bz2", "bunzip2 -c %s", \
207 ".zip", "unzip -p %s", \
208 ".lha", "lha -pq %s", \
209 ".lzh", "lha -pq %s", \
210 ".shn", "shorten -x %s -", \
213 TiMidity++ can handle some of archive format directly. But other
214 format will use this extractor.
218 Configuration of of patch file converter (please ignore in Windows).
221 #define PATCH_CONVERTERS { \
222 ".wav", "wav2pat %s", \
227 Configuration of extensions of GUS/patch file. If specified in this
228 configuration, the extension can omit in all *.cfg. By default:
230 #define PATCH_EXT_LIST { \
232 ".shn", ".pat.shn", \
234 ".bz2", ".pat.bz2", \
239 Configuration of default instrument. By default:
241 #define DEFAULT_PROGRAM 0
243 If no Program Change event, this program name are adopted. Usually 0
246 ** DEFAULT_DRUMCHANNELS
248 Configuration of drum channel. By default:
250 #define DEFAULT_DRUMCHANNELS {10, -1}
252 Numbers are the list of drum channels, and -1 is the terminator. For
253 example, if you wish to default drum channel be 10 and 16,
255 #define DEFAULT_DRUMCHANNELS {10, 16, -1}
257 This channel can change in command line option.
261 Type of floating point number. Choose one of these:
263 * typedef double FLOAT_T;
264 * typedef float FLOAT_T;
266 Many machine which has FPU results faster operations with double than
267 that with float. But some machine results contrary.
269 ** (MAX|MIN)_OUTPUT_RATE
271 Minimum/maximum range of playing sample rate. By default:
273 #define MIN_OUTPUT_RATE 4000
274 #define MAX_OUTPUT_RATE 65000
276 ** DEFAULT_AMPLIFICATION
278 Default value of master volume. By default:
280 #define DEFAULT_AMPLIFICATION 70
282 This number is the percentage of max volume. This default value will
283 be nice in any occasions. This number can specify in command line
288 Default sampling rate. By default:
290 #define DEFAULT_RATE 44100
292 If you have much CPU power, DAT quality GUS/patch and want to listen
295 #define DEFAULT_RATE 48000
301 Configuration of default polyphony numbers. By default:
303 #define DEFAULT_VOICES 256
305 DEFAULT_VOICE is the polyphony number in boot-time. This value is
306 configurable by the command line option (-p) from 1 to until memory is
307 allowed. If your machine has much CPU power,
309 #define DEFAULT_VOICES 512
311 enables good harmony.
315 Size of internal buffer. By default:
317 #define AUDIO_BUFFER_BITS 12
319 I guess this values no need to change.
321 ** CONTROLS_PER_SECOND
323 TiMidity++ do not calculate every envelope changes, but calculate some
324 samples at one time. Small controls yields better quality sound, but
325 also eat much CPU time. By default:
327 #define CONTROLS_PER_SECOND 1000
329 This can be changed from command line. Leave as it is.
331 ** DEFAULT_RESAMPLATION
333 Type of interpolation engine. By default:
335 #define DEFAULT_RESAMPLATION resample_gauss
337 This definition cause TiMidity++ to Gauss-like interpolation in re-
338 sampling, and the quality of sound would be nice. But it eats CPU
339 powers. I recommend define it if your machine has much power. Other
340 choices are (sorted by their speed):
342 #define DEFAULT_RESAMPLATION resample_none
343 #define DEFAULT_RESAMPLATION resample_linear
344 #define DEFAULT_RESAMPLATION resample_lagrange
345 #define DEFAULT_RESAMPLATION resample_cspline
346 #define DEFAULT_RESAMPLATION resample_gauss
347 #define DEFAULT_RESAMPLATION resample_newton
349 Interpolation methods are changeable from the command line. If you
350 want to prevent users from doing so, uncomment next line and define as
353 #define FIXED_RESAMPLATION
357 Configuration of USE_DSP_EFFECT to refine chorus, delay, EQ and
358 insertion effect. Default enabled.
362 Configuration of LOOKUP_HACK. By default, this features are undefined
365 /* #define LOOKUP_HACK */
366 /* #define LOOKUP_INTERPOLATION */
368 This option saves a little CPU power, but sound quality would decrease
369 noticeably. If your machine suffers from lack of CPU power, enable
374 Defining this greatly reduces popping due to large volume/pan changes.
375 This is definitely worth the slight increase in CPU usage.
379 Configuration of FAST_DECAY. By default:
381 /* #define FAST_DECAY */
383 This option makes envelopes twice as fast and saves CPU power. But
384 since the release time of voices is shorten, the sound would be poor.
385 This feature is controllable in command line option.
389 TiMidity++ uses fixed-point calculation. Its default is
391 #define FRACTION_BITS 12
393 and you don't have to change this value.
395 ** ADJUST_SAMPLE_VOLUMES
397 Configuration of adjusting amplitude of GUS/patch. By default:
399 #define ADJUST_SAMPLE_VOLUMES
401 This option makes TiMidity to adjust amplitudes of each GUS/patch to
406 By default this feature is disabled:
408 /* #define DANGEROUS_RENICE -15 */
410 If you want to increase process priority of TiMidity++ by using setuid
411 root enable this option. This option is only available in UNIX. Once
412 you enabled this option, you should install timidity with the follow-
415 # chown root /usr/local/bin/timidity
416 # chmod u+s /usr/local/bin/timidity
418 Note: You should not set setuid to timidity if DANGEROUS_RENICE isn't
423 If this value is too small, click noise would be come. Default is:
425 #define MAX_DIE_TIME 20
427 and I recommend this value leave to this.
433 On some machines (especially PCs without math coprocessors), looking
434 up sine values in a table will be significantly faster than computing
435 them on the fly. I recommend define it.
439 Configuration of optimizing re-sampling. By default:
441 #define PRECALC_LOOPS
443 These may not in fact be faster on your particular machine and
448 Configuration of use of ldexp(). By default this feature is disabled:
450 /* #define USE_LDEXP */
452 If your machine can multiply floating point number with ldexp() faster
453 than other method, enable this option.
455 ** DEFAULT_CACHE_DATA_SIZE
457 Size of pre-re-sampling cache. By default:
459 #define DEFAULT_CACHE_DATA_SIZE (2*1024*1024)
461 This can be changed from command line, so you don't have to change
464 * Configurations about network
466 TiMidity++ can access any files via networks with URL. This feature
467 are configurable in Makefile. If you have enabled this feature in
468 Makefile (configure --enable-network), configure the following macros:
472 specifies domain name of your name address. If your name address is
473 "iz@onicos.co.jp" set the macro:
475 #define MAIL_DOMAIN "@onicos.co.jp"
479 specifies mail name of yours if in Windows. In UNIX, uncomment it.
480 For example, your name address is "iz@onicos.co.jp" set the macro:
482 #define MAIL_NAME "iz"
486 Configuration of temporary directory. By default, this option is
489 /* #define TMPDIR "/var/tmp" */
491 In UNIX, if this option is disabled TiMidity++ creates temporary files
492 in the path specified by the environment variable TMPDIR. If environ-
493 ment variable TMPDIR also isn't defined, TiMidity++ creates temporary
494 files in /tmp. In Windows, TMPDIR variable are ignored. So you
495 should specify the temporary path with this macro.
499 Recognizing GS drum part by GS exclusive message.
503 enables to recognize GS exclusive message to set drum part.
505 /* #define GS_DRUMPART */
507 disables this feature.
509 * Japanese-text-handling related options
511 There are some options for Japanese handling.
515 If your system is in Japanese environment, define
519 otherwise comment it out like
521 /* #define JAPANESE */
525 specifies output text code (in Japanese environment). You should
526 specify appropriate code name to OUTPUT_TEXT_CODE macro. The follow-
527 ing strings are available:
530 Auto conversion by `LANG' environment variable (UNIX only)
532 Convert unreadable characters to '.' (0x2e)
536 Convert from windows-1251 to koi8-r
544 In Japanized UNIX system, all of above are available. In Windows,
545 "ASCII", "NOCNV", "SJIS" are available. If your environment cannot
546 handle Japanese, specify "ASCII" or "NOCNV" alternatively.
548 ** MODULATION_WHEEL_ALLOW
550 ** NRPN_VIBRATO_ALLOW
551 ** REVERB_CONTROL_ALLOW
552 ** FREEVERB_CONTROL_ALLOW
553 ** CHORUS_CONTROL_ALLOW
554 ** SURROUND_CHORUS_ALLOW
555 ** GM_CHANNEL_PRESSURE_ALLOW
556 ** VOICE_CHAMBERLIN_LPF_ALLOW
557 ** VOICE_MOOG_LPF_ALLOW
558 ** MODULATION_ENVELOPE_ALLOW
559 ** ALWAYS_TRACE_TEXT_META_EVENT
560 ** OVERLAP_VOICE_ALLOW
561 ** TEMPER_CONTROL_ALLOW
563 Controllers of MIDI actions. By default:
565 #define MODULATION_WHEEL_ALLOW
566 #define PORTAMENTO_ALLOW
567 #define NRPN_VIBRATO_ALLOW
568 /* #define REVERB_CONTROL_ALLOW */
569 #define FREEVERB_CONTROL_ALLOW
570 #define CHORUS_CONTROL_ALLOW
571 /* #define SURROUND_CHORUS_ALLOW */
572 /* #define GM_CHANNEL_PRESSURE_ALLOW */
573 #define VOICE_CHAMBERLIN_LPF_ALLOW
574 /* #define VOICE_MOOG_LPF_ALLOW */
575 /* #define MODULATION_ENVELOPE_ALLOW */
576 /* #define ALWAYS_TRACE_TEXT_META_EVENT */
577 #define OVERLAP_VOICE_ALLOW
578 #define TEMPER_CONTROL_ALLOW
580 These values are configurable in command line options. So you may
581 leave these in default value.
583 ======================================================================
585 ======================================================================
587 Make section has nothing particular to write. Just say "make"
589 ...Oops, almost forgot, TiMidity++'s Makefile needs GNU version of
590 make. If you do not have, get one first. If you have one in a
591 different name than "make", type its true name instead.
595 On UNIX and clones, you can type "make install" to install all files.
596 Or you can select following targets:
599 installs executable filles
601 installs Tcl/Tk interface
603 installs Emacs interface
609 I strongly recommend you to check the install destinations and files
610 by setteing -n flag like
614 ======================================================================
615 Search for voice data
616 ======================================================================
618 TiMidity++ uses Either GUS/patch, or SoundFont(, or both) as the voice
619 data to play. You must get a SoundFont or GUS/patch files, and make
620 the configuration file. You must make the configuration file (*.cfg).
621 By default, timidity.cfg is /usr/local/share/timidity/timidity.cfg (or
622 C:\WINDOWS\TIMIDITY.CFG on Windows). And please check the following
623 sites for many voice(patch) data:
625 * http://www.onicos.com/staff/iz/timidity/link.html#gus
626 * http://www.onicos.com/staff/iz/timidity/dist/cfg/ (Some sample *.cfg's)
627 * http://www.i.h.kyoto-u.ac.jp/~shom/timidity/ (10M and 4M patches)
628 * ftp://ftp.cdrom.com/pub/gus/sound/patches/files/ (GUS site)
630 If you got funny voice archive, extract it to appropriate directory
631 and configure *.cfg files with the name and path of these voice datas.