User:OliverCharles/DebianSetup

From MusicBrainz Wiki
Jump to navigationJump to search

MusicBrainz::Server runs really nicely on Debian. Here's how you can get it running! I'm using Debian 5.0.4 (which was stable, at the time of writing)

First, we need a few modules just to kick the build process off.

apt-get install libmodule-install-perl git-core build-essential

Now we can clone the core.git repository and build a Makefile to work from.

git clone git://git.musicbrainz.org/musicbrainz-server/core.git musicbrainz-server
cd musicbrainz-server
perl Makefile.PL

You'll see you don't have most of the modules. You could let the Makefile grab this all for you, but that's going to stick a load of junk all over you Debian system. And I don't like other people leaving their junk all around my house, do you? So, cancel that (keep answering 'no') and lets take care of the easy modules that have Debian packages:

apt-get install libcatalyst-modules-perl libcatalyst-view-tt-perl libdbd-pg-perl libexception-class-perl libhtml-tiny-perl liblocale-po-perl liblist-moreutils-perl libmoose-perl libossp-uuid-perl libreadonly-perl libstring-shellquote-perl libtest-differences-perl libxml-feed-perl libyaml-perl

Stable does not have everything we need though, so we will need to setup some more modules. For this, we will use the excellent local::lib to avoid putting stuff that's not Debian maintianed in our system (and keeping it in our home directory)

cd ~
wget http://search.cpan.org/CPAN/authors/id/A/AP/APEIRON/local-lib-1.004009.tar.gz
tar xzf local-lib-1.004009.tar.gz 
cd local-lib-1.004009
perl Makefile.PL --bootstrap
make test
make install
echo 'eval $(perl -I$HOME/perl5/lib/perl5 -Mlocal::lib)' >>~/.bashrc
. ~/.bashrc

This is just what it says to do on the local::lib CPAN page. Now, lets jump back in to installing the Perl modules we need (fully the prompts you get on screen):

cpan Test::Aggregate

If you get tired of saying "yes" what a dependency is encountered, you might want to do this:

cpan
o conf prerequisites_policy follow
o conf commit
quit