Other things on this site...

Evolutionary sound
Listen to Flat Four Internet Radio
Learn about
The Molecules of HIV
Make Oddmusic!
Make oddmusic!

How to make a debian package of SuperCollider

I've been making debian packages of SuperCollider recently. Here's a quick note of how to do it - it should work on any debian-based system though my experience is on ubuntu and puredyne:

First make sure you have the standard packages needed for getting and building things:

    sudo apt-get install build-essential debuild subversion gnupg \
      libfftw3-dev libsndfile1-dev scons libjack-dev libreadline6-dev \
      libicu-dev libavahi-client-dev libasound2-dev libcwiid1-dev \
      libxt-dev python-support sharutils chrpath

Then we'll create a folder "scdeb" in which to do our work, and in it we'll get a fresh checkout of the latest SuperCollider source:

    mkdir ~/scdeb
    cd ~/scdeb
    svn co https://supercollider.svn.sourceforge.net/svnroot/supercollider/trunk scsvn

Now, inside the source tree is a script which will build a neat source package for us (it strips out the SVN folders as well as various non-linux stuff):

    cd scsvn/common/Packager
    ./package -s

When this is done there's a .tar.gz file called something like SuperCollider-2010-02-22-Source-linux.tar.gz (the date will be today's date).

We'll need to move that around as well as unpack it into the special positions that debian's bundling expects (it's quite strict about the filenaming conventions):

    cd ~/scdeb
    cp scsvn/common/Packager/SuperCollider-2010-02-22-Source-linux.tar.gz supercollider_3.3.1~svn9872.orig.tar.gz
    tar zxvf supercollider_3.3.1~svn9872.orig.tar.gz
    mv SuperCollider-Source supercollider-3.3.1~svn9872

A couple of things to note about the filenames:

  • The .tar.gz also has that orig to indicate it's the "upstream" source without any debian patches or additions.
  • The .tar.gz name must always be the packagename, followed by underscore, followed by the version string. In my example I've used 3.3.1~svn9872 as the version string but you'll need to adapt that to whatever version you're actually packaging.
  • The extracted folder name is similar to the .tar.gz name EXCEPT that there's a dash (a minus sign) rather than an underscore - that's important!

OK, next we go into the nice clean source folder we've made, add the debian stuff, and edit the changelog to say what's new in this release.

     cd supercollider-3.3.1~svn9872
     svn export https://supercollider.svn.sourceforge.net/svnroot/supercollider/packages/ubuntu debian
     vim debian/changelog

The format of the changelog is again quite strict - I won't describe it here but search the web for debian changelog format to learn more. Don't include all the changes that have happened, only the ones relevant to this debian packaging (e.g. "fixed patch for debian paths", or also "new upstream release").

Now you're ready to do the build.


When that process finishes it'll ask you to sign the package using a GPG signature associated with your email address. (You can deactivate this signing using a flag to debuild, but if you don't sign it then no-one can trust where it came from so it won't be allowed into package repositories.)

Alternatively for a debian source package you can run

      debuild -S

Whichever of those two you run, you'll end up with packages built in the parent folder (~/scdeb) which you can install locally using dkpg -i or upload to ubuntu/debian using dput.

| linux | Permalink