| 1 |
AUTHOR: Alex Kloss <alex@22-music.com> |
|---|
| 2 |
|
|---|
| 3 |
DATE: 2003-08-20 |
|---|
| 4 |
|
|---|
| 5 |
LICENSE: GNU Free Documentation License |
|---|
| 6 |
|
|---|
| 7 |
SYNOPSIS: Ardour is a multitrack sound recorder/editor/mixer. |
|---|
| 8 |
|
|---|
| 9 |
DESCRIPTION: |
|---|
| 10 |
Ardour is somewhat like ProTools(tm), high quality multitracker. It's |
|---|
| 11 |
pretty easy to install, but needs a lot of additional fiddling |
|---|
| 12 |
(RT-Kernel patch, Jack Server and Ladspa). |
|---|
| 13 |
|
|---|
| 14 |
PREREQUISITES: |
|---|
| 15 |
|
|---|
| 16 |
Downloads: |
|---|
| 17 |
========== |
|---|
| 18 |
|
|---|
| 19 |
ardour http://ardour.sourceforge.net -> release or CVS version |
|---|
| 20 |
JACK http://jackit.sourceforge.net -> release version |
|---|
| 21 |
glib/gtk+ http://www.gtk.org -> 1.2.8 or newer, but not 1.3 or 2.0! |
|---|
| 22 |
libxml2 http://www.xmlsoft.org -> 2.5.X |
|---|
| 23 |
libart_lgpl on your local GNOME mirror, see BLFS section |
|---|
| 24 |
libsndfile http://www.zip.com.au/~erikd/libsndfile -> 1.0 or higher |
|---|
| 25 |
libsamplerate http://www.mega-nerd.com/SRC/ -> 0.0.13 or newer |
|---|
| 26 |
LADSPA SDK http://www.ladspa.org -> SDK and plugins of your liking |
|---|
| 27 |
raptor http://www.redland.opensource.ac.uk/raptor -> release |
|---|
| 28 |
liblrdf http://plugin.org.uk/lrdf/ -> 0.3.1 or higher |
|---|
| 29 |
|
|---|
| 30 |
and the RT-Scheduling-Patch for your kernel version: |
|---|
| 31 |
http://www.zip.com.au/~akpm/linux/schedlat.html |
|---|
| 32 |
|
|---|
| 33 |
Ardour requires to use ALSA as sounddriver. |
|---|
| 34 |
|
|---|
| 35 |
HINT: |
|---|
| 36 |
|
|---|
| 37 |
Installation order: |
|---|
| 38 |
=================== |
|---|
| 39 |
|
|---|
| 40 |
- Kernel Patch for RealTime Scheduling |
|---|
| 41 |
- ALSA sounddriver (if not already available, remember that the |
|---|
| 42 |
reinstallation of the kernel removes everything in the modules |
|---|
| 43 |
directory, so you may have to reinstall the driver) |
|---|
| 44 |
- glib |
|---|
| 45 |
- gtk+ |
|---|
| 46 |
- libxml2 |
|---|
| 47 |
- libsndfile |
|---|
| 48 |
- libsamplerate |
|---|
| 49 |
- LADSPA SDK (plus the plugins you want) |
|---|
| 50 |
- JACK |
|---|
| 51 |
- raptor |
|---|
| 52 |
- liblrdf |
|---|
| 53 |
- ardour |
|---|
| 54 |
|
|---|
| 55 |
There are already hints and/or BLFS sections for ALSA, glib, gtk, |
|---|
| 56 |
libxml2, so these packages will not be discussed again. Please refer to |
|---|
| 57 |
their instructions. |
|---|
| 58 |
|
|---|
| 59 |
Discussion: Starting Jack/Ardour as root or patching the kernel: |
|---|
| 60 |
================================================================ |
|---|
| 61 |
|
|---|
| 62 |
If your system is faster than the average (and even a slow hdd can |
|---|
| 63 |
kill that advantage) or you don't think you need Realtime scheduling, |
|---|
| 64 |
you can leave all following instructions about the kernel undone. |
|---|
| 65 |
|
|---|
| 66 |
There are 2 ways of starting JACK (and thusly ardour) with realtime |
|---|
| 67 |
latency, once your kernel is patched: |
|---|
| 68 |
|
|---|
| 69 |
- start jack as root (need to start ardour as root, too; insecure) |
|---|
| 70 |
- apply givertcap patch: |
|---|
| 71 |
|
|---|
| 72 |
edit /usr/src/linux/include/linux/capability.h: |
|---|
| 73 |
|
|---|
| 74 |
where it says: |
|---|
| 75 |
|
|---|
| 76 |
#define CAP_INIT_EFF_SET to_cap_t(~0 & ~CAP_TO_MASK(CAP_SETPCAP)) |
|---|
| 77 |
#define CAP_INIT_INH_SET to_cap_t(0) |
|---|
| 78 |
|
|---|
| 79 |
change the lines so it will read: |
|---|
| 80 |
|
|---|
| 81 |
#define CAP_INIT_EFF_SET to_cap_t(~0) |
|---|
| 82 |
#define CAP_INIT_INH_SET to_cap_t(~0) |
|---|
| 83 |
|
|---|
| 84 |
and go on with patching your kernel for RT scheduling. |
|---|
| 85 |
|
|---|
| 86 |
I myself prefer the last way, but you may choose yourself. |
|---|
| 87 |
|
|---|
| 88 |
Patching your kernel: |
|---|
| 89 |
===================== |
|---|
| 90 |
|
|---|
| 91 |
cd /usr/src/linux # (or wherever you have your kernel sources) |
|---|
| 92 |
bzcat <patch> | patch -Np1 # fill in the appropriate name for "<patch>" |
|---|
| 93 |
make menuconfig # and select real time scheduling |
|---|
| 94 |
make dep |
|---|
| 95 |
make clean |
|---|
| 96 |
make bzImage |
|---|
| 97 |
make modules |
|---|
| 98 |
make modules_install |
|---|
| 99 |
|
|---|
| 100 |
now copy the bzImage in arch/<arch*>/boot/ to /boot, edit your |
|---|
| 101 |
/etc/lilo.conf to your needs and run lilo [*fill in whatever is |
|---|
| 102 |
appropriate, this will be i386 in most cases]. Now restart your system. |
|---|
| 103 |
|
|---|
| 104 |
|
|---|
| 105 |
Install ALSA, glib, gtk+ and libxml2 (when in doubt, look at the related |
|---|
| 106 |
BLFS section/hints). |
|---|
| 107 |
|
|---|
| 108 |
Installing every other package: |
|---|
| 109 |
=============================== |
|---|
| 110 |
|
|---|
| 111 |
all those packages are easy enough installed with |
|---|
| 112 |
|
|---|
| 113 |
./configure --prefix=/usr && |
|---|
| 114 |
make && |
|---|
| 115 |
make install |
|---|
| 116 |
|
|---|
| 117 |
Starting ardour: |
|---|
| 118 |
================ |
|---|
| 119 |
|
|---|
| 120 |
To start ardour, you need to ensure no other process is holding the |
|---|
| 121 |
sound devices, start the jack server and then ardour and don't forget to |
|---|
| 122 |
remove the jack server afterwards. Because we're a lazy bunch, well do |
|---|
| 123 |
that with a script. You'll have to edit it to your needs |
|---|
| 124 |
|
|---|
| 125 |
--snip |
|---|
| 126 |
#!/bin/bash |
|---|
| 127 |
# |
|---|
| 128 |
# Ardour Startscript |
|---|
| 129 |
# |
|---|
| 130 |
# Variable declarations |
|---|
| 131 |
JACKD=jackstart |
|---|
| 132 |
JACKOPTS="-a -R -d alsa -d ice1712 -p 512" |
|---|
| 133 |
# replace "ice1712" with your soundcard's identifier! |
|---|
| 134 |
JACKD_ALREADY_RUNNING=0 |
|---|
| 135 |
|
|---|
| 136 |
# find out whether jackd is already running |
|---|
| 137 |
for i in /proc/*/cmdline; do |
|---|
| 138 |
CMDLINE=$(<$i) |
|---|
| 139 |
if [ "$CMDLINE" != "${CMDLINE#$JACKD}" ]; then |
|---|
| 140 |
JACKD_ALREADY_RUNNING=1 |
|---|
| 141 |
fi |
|---|
| 142 |
done |
|---|
| 143 |
|
|---|
| 144 |
# if jackd isn't yet running, we start it |
|---|
| 145 |
if [ "$JACKD_ALREADY_RUNNING" = "0" ]; then |
|---|
| 146 |
# but first we need to kill all processes that locks sound devices |
|---|
| 147 |
fuser -k /dev/admmidi? /dev/adsp? /dev/amidi? /dev/audio* /dev/dmfm* \ |
|---|
| 148 |
/dev/dmmidi? /dev/dsp* /dev/dspW* /dev/midi0? /dev/mixer? /dev/music \ |
|---|
| 149 |
/dev/patmgr? /dev/sequencer* /dev/sndstat >/dev/null 2>&1 |
|---|
| 150 |
if [ -d /proc/asound/dev ]; then |
|---|
| 151 |
fuser -k /proc/asound/dev/* >/dev/null 2>&1 |
|---|
| 152 |
fi |
|---|
| 153 |
if [ -d /dev/snd ]; then |
|---|
| 154 |
fuser -k /dev/snd/* >/dev/null 2>&1 |
|---|
| 155 |
fi |
|---|
| 156 |
# and now start jack |
|---|
| 157 |
$JACKD $JACKOPTS &> /dev/null & |
|---|
| 158 |
fi |
|---|
| 159 |
|
|---|
| 160 |
# now we are ready to start ardour with all options we were called with |
|---|
| 161 |
ardour -n "$@" |
|---|
| 162 |
|
|---|
| 163 |
# afterwards, if jack wasn't already running (we presume that would be |
|---|
| 164 |
# for a reason), kill the jackd. |
|---|
| 165 |
|
|---|
| 166 |
if [ "$JACKD_ALREADY_RUNNING" = "0" ]; then |
|---|
| 167 |
for i in /proc/*/cmdline; do |
|---|
| 168 |
if [ "$(<$i)" = "$JACKD$(echo $JACKOPTS | sed s/\ //g)" ]; then |
|---|
| 169 |
pidbackup=${i#/proc/} |
|---|
| 170 |
pid=${pidbackup%/cmdline} |
|---|
| 171 |
kill -9 $pid |
|---|
| 172 |
fi |
|---|
| 173 |
done |
|---|
| 174 |
fi |
|---|
| 175 |
|
|---|
| 176 |
# end of ardour-start |
|---|
| 177 |
|
|---|
| 178 |
--snap |
|---|
| 179 |
|
|---|
| 180 |
copy that script to /usr/bin/ardour-start and run |
|---|
| 181 |
|
|---|
| 182 |
chmod 755 /usr/bin/ardour-start |
|---|
| 183 |
|
|---|
| 184 |
CHANGELOG: |
|---|
| 185 |
[2003-08-20] |
|---|
| 186 |
* Initial hint. |
|---|