Downloading and Installing the Distribution

The MusicKit can be installed from a binary distribution package or compiled from the source code distribution tarball. In either case, certain libraries must be preinstalled for the MusicKit to operate.

Installing Supporting Libraries

The following libraries need to be installed prior to compiling the MusicKit source or before attempting to link against the MusicKit frameworks. These supporting libraries may be installable using fink, or they can be individually downloaded and compiled as described below. Certain libraries may be optionally omitted (reducing functionality of the MusicKit) if necessary. These are noted below.

Note

If installing on GNUstep, be sure that PKG_CONFIG_PATH is set to point to whereever you install the libraries listed below. For example, if you do install these in /usr/local/lib, PKG_CONFIG_PATH should be set to /usr/local/lib/pkgconfig. See pkg-config for details.

libogg-1.1.4.tar.gz. Status: optional - disables SndAudioProcessorMP3Encoder if omitted., libvorbis-1.2.2.tar.gz. Status: optional - disables SndAudioProcessorMP3Encoder if omitted.

The Ogg/Vorbis libraries provide patent-free Vorbis encoding/decoding of PCM audio to and from Ogg format bitstreams for use by libshout. Newer versions than 1.1.4 for Ogg and 1.2.2 for Vorbis will probably just work.

Install the library using:

tar xzvf libogg-1.1.4.tar.gz
cd libogg-1.1.4
sh ./configure
sudo make install
cd ..
tar xzvf libvorbis-1.2.2.tar.gz
cd libvorbis-1.2.2
sh ./configure
sudo make install

libsndfile-1.0.20.tar.gz. Status: optional - disables Snd file I/O and SndAudioProcessorRecorder if omitted.

The libsndfile sound file I/O library provides sound file format conversion. Newer versions than 1.0.20 will probably just work.

Install the library using:

tar xzvf libsndfile-1.0.20.tar.gz
cd libsndfile-1.0.20
sh ./configure
sudo make install

lame-3.98.2.tar.gz. Status: optional - disables SndAudioProcessorMP3Encoder if omitted.

The LAME library provides MP3 encoding/decoding capability. Newer versions than 3.98.2 will probably just work.

Install the library using:

tar xzvf lame-3.98.2.tar.gz
cd lame-3.98.2
sh ./configure
sudo make install

icecast-2.3.2.tar.gz. Status: optional - disables SndAudioProcessorMP3Encoder if omitted.

The libshout library (part of the IceS distribution) of the icecast project provides the capability to stream MP3 or Ogg/Vorbis encoded audio to a broadcast server.

Install the library using:

tar xzvf icecast-2.3.2.tar.gz
cd icecast-2.3.2
sh ./configure --without-python --disable-dependency-tracking
make
sudo make install

pa_snapshot_v19.tar.gz. Status: Needs to be installed on Windows, Linux and other Unixen except for MacOS X, OpenStep/NeXTStep systems.

At the moment, the portaudio Subversion repository version is the only version that works on MinGW and so MKPerformSndMIDI_portaudio uses the upcoming V19 release. Either fetch the Subversion snapshot, or using Subversion, checkout the portaudio version 19 development branch. On Linux/BSD/SGI etc do:

cvs -d:pserver:anonymous@www.portaudio.com:/home/cvs co -r v19-devel portaudio
cd portaudio
./configure --without-oss --libdir=$GNUSTEP_SYSTEM_ROOT/Libraries
 --includedir=$GNUSTEP_SYSTEM_ROOT/Local/Libraries/Headers
sudo make install

On Windows XP do:

cvs -d:pserver:anonymous@www.portaudio.com:/home/cvs co -r v19-devel portaudio
cd portaudio
./configure --libdir=$GNUSTEP_SYSTEM_ROOT/Libraries
 --includedir=$GNUSTEP_SYSTEM_ROOT/Local/Libraries/Headers
--with-winapi=directx
--with-dxdir=/c/DXSDK
sudo make install

libmp3hip-0.4pre1.tar.gz. Status: optional - disables SndMP3 if omitted.

The libmp3hip library of the LAME project provides the MP3 decoding

Install the library using:

tar xzvf libmp3hip-0.4pre1.tar.gz
cd libmp3hip-0.4pre1
sh ./configure
make
sudo make install

Installing MusicKit Binaries

Binaries for the compiled frameworks for various operating systems reside on sourceforge as .dmg (Apple), or .rpm (Linux) packages. The files include the version number, choose the most recent release:

MK-5.6.2.b.MOX.dmg

The MacOS X frameworks (including the SndKit), applications, command line tools and documentation.

ZilogSCCMIDI.b.tar.gz

The MacOS X-Server V1.2 MIDI driver binary for SCC UARTs in 8500/8600/9500/9600/G3/G4 PowerMacs.

Note

This driver is not needed and will not work on MacOS X, only MacOS X-Server V1.2.

Installation Locations

The Installer program will let you choose a directory in which to place the binaries. If you are on a stand-alone machine, you should be logged in (or running Installer) as root and choose “/” for the installation directory (the default).

The frameworks and applications are installed into the appropriate platform locations given in Table 2.

Table 2. MusicKit Install locations

PlatformFrameworks install locationApplications install location
OpenStep 4.2 (m68k,ix86)/LocalLibrary/Frameworks/LocalApps
MacOS X-Server V1.0-1.2/Local/Library/Frameworks/Local/Apps
MacOS X/Library/Frameworks/Applications
GNUStep (on Unixen)/usr/GNUstep/Local/Library/Frameworks/usr/GNUstep/Local/Applications
GNUStep (on Windows)C:\GNUstep\Local\Library\FrameworksC:\GNUstep\Local\Applications

Command line tools and manual pages will install into the /usr/local hierarchy on Unix type machines, specifically /usr/local/bin. Locations for command line Windows tools have yet to be determined.

If you are the system administrator for a NFS shared network, you probably want to choose a local directory which can be exported and create symbolic links into that directory on the networked machines. Alternatively, if you have a single server that exports /Local* and /usr/local, simply install the package there and you're done.

Installing From The Source Tarball

The source distribution is located at:

MK-5.6.2.s.tar.gz

The source to MusicKit, SndKit, MKDSP, MKPerformSndMIDI, MKUnitGenerators and MKSynthPatches frameworks and all utilites, applications, documentation and example code.

This is the most recent revision and patch. Some older revisions are located at the sourceforge site for regression testing.

ZilogSCCMIDI.s.tar.gz

The MacOS X-Server V1.0-1.2 MIDI driver source.

Note

This is not needed for MacOS X.

DriverKitHeadersForMOXS_V1.2.tar.gz

NeXTStep V3.3 headers required to compile the driver on MacOS X-Server V1.2.

Note

This is not needed for MacOS X.

Retrieving Sources From The Subversion Repository

The bleeding edge source is obtainable from the Subversion repository on sourceforge and is described in detail by this sourceforge page.

Compiling The Sources

The MusicKit installation process is now practically the same as most autoconf configured software. Trivially, the following commands will compile and install the MusicKit.

./configure
make
sudo make install

If you are installing dependent libraries into a non-standard place such as /sw if using fink on MacOS X, you can use the standard configure method to specify the compilation and linking flags:

./configure CPPFLAGS=-I/sw/include LDFLAGS=-L/sw/lib
make
sudo make install

There are a couple of subtle variations to this, explained below.

Building on GNUstep

On GNUstep systems, make is responsible for building the MusicKit sources. From the top level of the source tree, executing make should build Frameworks, Examples and Applications. Note that the applications and tools built may differ from the MacOS X set due to missing GNUmakefile definitions, but we aim to produce the same files on all platforms.

At the time of writing, GNUstep isn't able to build frameworks which depend on earlier built frameworks automatically. This requires installing each MusicKit framework individually, in order, in a similar fashion to the frameworks of GNUstep themselves. Also, the environment variables required by GNUstep for building must be defined while having root permissions in order to install. This is achieved with the following commands:

% ./configure
% sudo sh
# . /usr/GNUstep/System/Library/Makefiles/GNUstep.sh
# cd Frameworks/PlatformDependent/MKPerformSndMIDI_portaudio
# make install
# cd ../../SndKit
# make install
# cd ../MKDSP_Native
# make install
# cd ../MusicKit
# make install
# cd ../..
# make install

Building on MacOS X

On MacOS X, to benefit from the Xcode IDE (the IDE, plus zero-linking), make will just run the xcodebuild command line tool which does the actual building using the MusicKit.xcodeproj project. If configure determined some libraries were unavailable, they will be omitted from the CONFIGURED_LIBS variable passed on the command line when xcodebuild is run by make. Since xcodebuild install builds and then installs, the sudo make install suffices, typing a preceding make is not actually necessary.

The MusicKit project can also be built within the Xcode IDE GUI. However configure must be run before building with Xcode, in order to configure headers to selectively compile sources based on library availability. In addition, the default configuration is to assume if the Xcode GUI is being used, then the MusicKit is being developed, not just installed and that all libraries have been installed. If all of the libraries are not available, the build setting CONFIGURED_LIBS must be changed for the SndKit to remove those libraries which are not installed. In practice, the user must manually modify CONFIGURED_LIBS build setting in the SndKit target to match the setting in Makefile.

To build on MacOS 10.6, currently the MusicKit and SndKit frameworks must be built for the i386 32 bit architecture. This requires the supporting libraries to also be built as i386 binaries. Assuming the support libraries are built with an i386 architecture binary, configure needs to be instructed to test the library linking with the i386 architecture, using the -arch flag:

./configure CFLAGS="-arch i386"
make

Note

The MKUnitGenerators and MKSynthPatches frameworks won't compile on platforms other than OpenStep or NeXTStep because the Motorola asm56000 and lnk56000 tools are missing.

Installing a MIDI driver

If necessary, compile and install an appropriate MIDI driver.

To compile the MacOS X-Server V1.2 Zilog SCC MIDI driver, some header files are missing. You can get them from the Darwin distribution of the SoundKit, copy them from a NeXTStep 3.3/OpenStep 4.2 system, or as a convience, they are made available for download.

MacOS X Developer release includes source for a generic USB MIDI driver at /Developer/Examples/CoreAudio/MIDI/SampleUSBDriver. There is also a driver binary for the MIDIMan MIDISPORTUSB interfaces for MacOS X available for download from MIDIMan's web page and other vendors may well have drivers available for their hardware.

Building the Documentation

The documentation for the MusicKit and SndKit are now authored in DocBook SGML format. This is then rendered to HTML, PDF, Apple HelpViewer and potentially other formats. In order to convert the documentation to these usual output formats, tools such as openjade, TeX, doxygen need to be installed in addition to DocBook itself. The configure command will check for these tools. The make command will attempt to build and install as much of the documentation as possible based on which tools have been installed. This is invoked by:

make documentation
sudo make installdocs