== Setting up a Buildbot slave on Ubuntu and Debian
For Ubuntu and Debian, a quick way to install all of the autotools and compilers needed are this:
<<code lang=sh>>
sudo apt-get build-dep mysql-server-5.0
<</code>>
Recent versions of bzr for older versions of Ubuntu are available on https://launchpad.net/~bzr/+archive/ppa.
On more exotic platforms it can be tricky to install everything needed, however such platforms are also much more valuable to get a broader coverage of the code than just another x86 Linux build. So do not hesitate to ask for help on the [[https://launchpad.net/~maria-developers|maria-developers]] mailing list.
The BuildBot manual can be a bit overwhelming, as it contains a **lot** of information. As additional help, here are the steps that were used to set up the "valgrind" build slave in our BuildBot. This was set up on an Ubuntu Hardy host. The steps used here should be useful as a starting point for other slaves, though details may differ:
First install buildbot and create a slave:
<<code lang=sh>>
sudo apt-get install buildbot
sudo -u buildbot buildbot create-slave --usepty=0 /var/lib/buildbot/maria-slave hasky.askmonty.org:9989 valgrind <passwd>
<</code>>
Next create a shared bzr repository in the builddir; this allows to save history between branches, greatly saving on necessary bandwidth usage against Launchpad:
<<code lang=sh>>
HOME=/var/lib/buildbot; sudo -u buildbot bzr init-repo maria-slave/valgrind
<</code>>
//(note the setting of $HOME to avoid bzr picking up stuff from local home directory)//
Put some appropriate info in /var/lib/buildbot/maria-slave/info
For Ubuntu Hardy, /etc/default/buildbot is used to configure start/stop of the slave at boot, like this:
<<code lang=sh>>
HOME=/var/lib/buildbot
BB_NUMBER[0]=0 # index for the other values; negative disables the bot
BB_NAME[0]="valgrind-ext" # short name printed on startup / stop
BB_USER[0]="buildbot" # user to run as
BB_BASEDIR[0]="$HOME/maria-ext" # basedir argument to buildbot (absolute path)
BB_OPTIONS[0]="" # buildbot options
BB_PREFIXCMD[0]="" # prefix command, i.e. nice, linux32, dchroot
<</code>>
(again, $HOME is set for the benefit of bzr).
Finally, start it. On Ubuntu Hardy:
<<code lang=sh>>
sudo /etc/init.d/buildbot start
<</code>>