I bet you're wondering, why oh why would you want to compile Subversion? Can't you just install it with apt-get or Synaptic?
The answer is: yes, you can install it with apt. But my problem: if you set up a project with the latest EasyEclipse, the Subversion client version in EasyEclipse is different from the Ubuntu Subversion client version. This means any projects you create with EasyEclipse and link to a Subversion repository are unusable with the command line svn client in Ubuntu Dapper. You get this message if you try:
$ svn stat svn: This client is too old to work with working copy '.'; please get a newer Subversion client
(By the way, I also get this error if I try to use script/plugin for a Rails application inside a project created with EasyEclipse. Presumably because the Ruby Subversion client library isn't up to date as a consequence of the C client library being out of date. This makes it difficult to use the plugin script, so I've been manually adding svn:externals to my plugins directory.)
First, download Subversion itself (I got the tarball) from the Subversion site. I'm using Subversion 1.4.3.
Next, install all the pre-requisites for compiling. I cribbed this list from http://packages.debian.org/stable/source/subversion:
sudo apt-get install m4 debhelper libneon24-dev libapr0-dev libdb4.3-dev libtool \ libexpat1-dev zlib1g-dev bison patch autotools-dev autoconf swig libsasl2-dev \ perl libperl-dev libkrb5-dev
Just for good measure (and because I don't really know what I'm doing :) I installed all the dependencies listed at http://packages.debian.org/stable/devel/subversion, plus all the -dev versions too:
sudo apt-get install db4.3-util libapr0 libapr0-dev libc6 libc6-dev libdb4.3 \ libexpat1 libexpat1-dev libldap2 libldap2-dev libneon24 libneon24-dev \ libssl0.9.7 libxml2 libxml2-dev patch zlib1g zlib1g-dev
Next, connect to the unpacked Subversion source directory and run these commands:
./configure --prefix=<path_to_install_directory>/subversion-1.4.3 --disable-nls make make install
Replacing <path_to_install_directory> with the path to the install directory. The --disable-nls turns off gettext support (for internationalisation) which otherwise causes problems.
Now try running:
<path_to_install_directory>/subversion-1.4.3/bin/svn --version svn, version 1.4.3 (r23084) compiled Mar 12 2007, 23:33:51
It works for me. It could be there are other dependencies I've missed or not listed, but you can get what the Debian developers think the dependencies are from the links in the text above.
By the way, it took me about two hours of debugging wierd error messages to get this working, so there's a chance you might get the same, of course. Here are a few examples of what I ended up googling:
I'm pretty sure these were caused by problems with OpenSSL and Neon, but I'm not 100% sure.
Comments
prevu
If you have to do this even occassionally then you really want to check out prevu which is the automated way of backporting ubuntu apps correctly:
https://wiki.ubuntu.com/Prevu
Cheers for that, I'd never
Cheers for that, I'd never heard of it before.