Keep [C]*(od|do)ing

February 14 th

2

Install Subversion 1.5.5 on Bluehost 64bit Box

Filed under: Tools, software — Tags: , , — Liwen @ 11:55 pm

The first thing I do before start typing code at home is to put it under version control system; the first thing I tried to do when had a SSH enabled reliable hosting, of course, was to set up Subversion server on it.

There are already several tutorials in the Internet, why I am writing this again? Well, I just wanted to prove that I too, can write blog! Among all those tutorials, none of them worked for me, I guess either I was trying to install the newest version of SVN or the BlueHost hosting environment has changed, or they just hate me. So I am constructing this and hope to contribute something I learned along the frustrating process of setting up SVN on 64bit shared hosting so you don’t need to smash your keyboard.

Once you enabled SSH on BlueHost control panel with a photo ID, it’s time to set up Subversion.

1. Open a terminal, type in:
ssh username@yourdomain.com
and hit enter, then input your hosting password.

2. It’s better to create a separate folder for all the operations, in case our home directories got messed up by any mistakes.

mkdir src
cd src

3. Download Subversion and dependencies:

wget http://subversion.tigris.org/downloads/subversion-1.5.5.tar.gz
wget http://subversion.tigris.org/downloads/subversion-deps-1.5.5.tar.gz
tar -xzvf subversion-1.5.5.tar.gz
tar -xzvf subversion-deps-1.5.5.tar.gz
cd subversion-1.5.5

4. Install apr and apr-util, notice the var LDFLAGS , it’s 64 bit, it’s m-A-g-I-c.

cd apr
./configure --enable-shared --prefix=$HOME LDFLAGS="-L/lib64"
make && make install

cd ../apr-util
./configure --enable-shared --prefix=$HOME
--with-apr=$HOME --without-berkeley-db LDFLAGS="-L/lib64"
make && make install

5. Install neon, I had been stuck here for an hour because of the 64 bit mode problem, remember to explicitly enable compilation of shared libraries and prefix the files into home directory.

cd ../neon
EXTRA_CFLAGS="-L/lib64 -fPIC"
CFLAGS="-L/lib64 -fPIC"
./configure --prefix=$HOME --enable-shared LDFLAGS="-L/lib64" --with-libs=$HOME
make && make install

6. Install Subversion, pass --without-apxs and --without-apache to prevent svn installing Apach modules, also you need to explicitly specify the dependencies.

cd ../
./configure --prefix=$HOME --without-berkeley-db --with-apr=$HOME --with-apr-util=$HOME --with-neon=$HOME
-without-apxs --without-apache
make && make install

7. Modify .bash_profile and .bashrc file

nano -w .bash_profile (pico is always my favourite.)
add $HOME/system/bin to PATH variable, it should look like this:
PATH=$PATH:$HOME/bin:$HOME/system/bin
Also add this line to your .bashrc file, after the ‘fi
PATH=$PATH:$HOME/bin

8. Logout the current session and log on again, let’s try:
mkdir ~/repos
cd repos
svnadmin create topsecrets007plus

now you can access your repository like this:
svn+ssh://username@host/home/username/repos/topsecrets007plus/
just replace username with your 8-character user name given by BlueHost.

2 Comments »

  1. [...] Posts: 1. Install Subversion 1.5.5 on Bluehost 64bit Box 2. Configure svn+ssh on [...]

    Pingback by Passwordless svn+ssh access in Mac OS X « Keep [C]*(od|do)ing — May 3, 2009 @ 8:57 pm

  2. [...] may want to refer to this post to see how I installed subversion in the first place as the following steps are partially in the [...]

    Pingback by Save Subversion Server on BlueHost « Keep [C]*(od|do)ing — June 15, 2009 @ 2:30 pm

RSS feed for comments on this post. TrackBack URL

Leave a comment

Powered by Wordpress | All rights reserved, all wrongs observed. @ 2009 Liwen Zhang (17 queries. 0.260 seconds.)