TiMidity++ Installation Instructions

This document describes how to install TiMidity++*1 for your UNIX-like machine.

You can configure and make timidity.exe on the Cygwin environment of Windows 98/95/NT. If you are in Windows, install Cygwin*2 (or mingw) if you do not have them.

Today's Macintosh has FreeBSD userland, so things described here would fly. Methods for older Macintosh*3 are not described here.

*1 Things in this document are for TiMidity++ version 2.12.0-pre1b or later.

*2 <URL:http://www.cygwin.com/>

*3 "Classic" environments


Basic Installation

The simplest way

TiMidity++ uses GNU autotools to build. So the simplest way to compile this package is:

  1. "cd" to the directory containing TiMidity++'s source code and type "./configure" to configure the package for your system. If you are using csh on an old version of System V, you might need to type "/bin/sh ./configure" instead to prevent csh from trying to execute configure itself.

    Running configure takes a while. While running, it prints some messages telling which features it is checking for.

  2. Type "make" to compile the package.
    NOTE: this make method requires GNU make. So if your system has it as gamke, type "gmake" instead.
  3. Type "make install" to install the programs and any data files and documentation.

More complecated way

The full installation process is:

  1. configre
  2. edit common.makefile, Makefile, timidity.h if necessery
  3. make
  4. installation
  5. set up voice data

Each processes are explained in following sections. *4

1: ./confgure

First, execute the following command:

% /bin/sh ./configure --help

Many options of configure will be displayed. Most of them, such as --help, --prefix=PREFIX, and so on are the regular ones. They exisits on most package that uses autoconf and you do not have to worry about their behavior.

There also exists some options that is typical to TiMidity++. Main of these are the following:

--enable-debug

Enables debug. Things will be compiled with debugging methods/informations.

--without-x

TiMidity++ uses X by default. So you must specify this option to prevent linker from linking X libraries.

--enable-audio[=audio_list]

Enables TiMidity++ to play MIDI files. If --enable-audio=no, TiMidity++ acts as a MIDI-to-WAVE converter.

You can specify one or more audio-device listed below *6.

  • default: Automatically select audio device.
  • oss: OSS /dev/dsp
  • sun: SunOS /dev/audio
  • hpux: hp-ux /dev/audio
  • irix: IRIX audio library
  • mme: OSF/1 MME
  • sb_dsp: BSD/OS 2.0 /dev/sb_dsp
  • w32: Windows MMS
  • darwin: MacOSX/darwin's CoreAudio frameowrk
  • alsa: ALSA pcm device
  • alib: hp-ux network audio (Alib)
  • nas: NAS
  • arts: aRts
  • esd: EsounD
  • vorbis: ogg vorbis
  • gogo: mp3 Gogo-No-Coder (Windows only)
--enable-interface[=interface_list]
--enable-dynamic[=interface_list]

Specify which interface to use. If you use --enable-dynamic instead of --enable-interface, the interfaces specified will be linked dynamically and the binary size would become a bit smaller.

You can select one or more interfaces listed below *6.

  • ncurses: Ncurses interface. timidity's -in option will invoke this interface.
  • slang: slang interface. timidity's -is option will invoke this interface.
     slang interface is similar to ncurses interface.
  • motif: Motif interface. timidity's -im option will invoke this interface.
     Motif interface also works under lestiff.
  • tcltk: Tcl/Tk interface. timidity's -ik option will invoke this interface.
  • emacs: Emacs front-end. Type M-x timidity to invoke.
  • vt100: The full-screen interface using VT100 terminal control codes. timidity's -iT option will invoke this interface.
  • xaw: X Athena Widgets interface. timidity's -ia option will invoke this interface.
  • xskin: X skin interface. timidity's -ii option will invoke this interface.
     see README.xskin for more information.
  • gtk: GTK+ interface. timidity's -ig option will invoke this interface.
  • w32gui: Build as Windows GUI binary.
  • winsyn: Build as TiMidity++ Windows Synthesizer server ("twsynth").
  • alsaseq: Build as ALSA sequencer client.

Note that
--enable-interface=INTERFACE1,INTERFACE2,...
equals as
--enable-INTERFACE1=yes --enable-INTERFACE2=yes ...
and for the same way,
--enable-dynamic=INTERFACE1,INTERFACE2,...
equals as
--enable-INTERFACE1=dynamic --enable-INTERFACE2=dynamic ...

--enable-network

Enables network support. This will allow TiMidity++ to open a MIDI file via network. You can specify the location of MIDI files by http://foo.com.tw/bar/baz.mid - like format.

--enable-spectrogram

With this option specified, TiMidity++ can open a window on X and show sound-spectrogram there.

--enable-wrd

WRD is a Japanese local lyric-contents format. This option enables WRD interface (on X).

Some MIDI files eat too much CPU power. If you choose correct optimizing method, TiMidity++ can play such MIDI files smoothly.

You can tell configure which optimizing method to use by following environmental variables:

  • CC: the C compiler command *7.
  • CFLAGS: flags to pass to ${CC} *8.
  • LDFLAGS: flags to pass to linker *9.
  • CPPFLAGS: flags to pass to preprocessor *10.

Your compiler may have many optimization flags. If you use gcc, gcc's online manual is available and there is the list of flags. For example, in case of ultrasparc/gcc, you can specify:

% env CFLAGS='-O3 -Wall -mv8 -funroll-all-loops -fomit-frame-pointer -mcpu=ultrasparc' /bin/sh configure [configure-options]...

or in case of PowerPCG4/gcc3 you can specify:

% env CFLAGS='-O3 -Wall -std=gnu99 -funroll-all-loops -fomit-frame-pointer -fforce-addr -mcpu=7450 -mpowerpc-gpopt -mpowerpc-gfxopt -mmultiple' /bin/sh configure [configure-options]...

and the binary will (hopefully) run faster.

2: Edit some files

If make fails, or if you want to change some parameters, edit common.makefile, Makefile, or timidity.h manually.

Parameters in timidity.h

There are some options that are hard-coded into timidity binary. They are #define-ed in timidity.h. You have to change things there if you want to change these flags...

This section is still under construction. sorry.

3: make

Make section has nothing particular to write. Just sa "make"

...Oops, almost forgot, TiMidity++'s Makefile needs GNU version of make. If you do not have, get one first. If you have one in a different name than "make", type its true name instead.

3: Installation

On UNIX and clones, you can type"make install" to install all files. Or you can select following targets:

  • install.bin: installs executable filles
  • install.tk: installs Tcl/Tk interface
  • install.el: installs Emacs interface
  • install.man: installs man files
  • install: installs everything

I strongly recommend you to check the install destinations and files by setteing -n flag like

% make -n ...

*4 Note that % is the shell prompt.

*5 audio_list should be a comma-separated list.

*6 audio_list should be a comma-separated list.

*7 e.g. "/usr/bin/gcc"

*8 e.g. "-O2 -pipe"

*9 e.g. "-L/usr/gnu/lib"

*10 e.g. "-traditional-cpp"


search for voice data

TiMidity++ uses Either GUS*11/patch, or SoundFont (,or both) as the voice data to play. You must get a SoundFont or GUS/patch files, and make the configuration file. You must make the configuration file (*.cfg). By default, timidity.cfg is /usr/local/share/timidity/timidity.cfg*12. And please check the following sites for many voice(patch) data:

If you got funny voice archive, extract it to appropriate directory and configure *.cfg files with the name and path of these voice dates.

*11 Note that % is the shell prompt.

*12 or C:\WINDOWS\TIMIDITY.CFG on Windows.