sensimevanidus

17 July, 2010

SVN Repository Relocation

Our SVN server has its own IP 192.168.1.200 in our local network and we use svnserve as the server program.

A few minutes ago, I needed to change the name of a repository from hede to hede.web and I did it this way:

On the server, i ran this command:

/var/repo$ mv hede hede.web

Then, on my development environment I needed to update the working copy:

~$ cd /var/www/svn_hede
/var/www/svn_hede$ svn switch svn://192.168.1.200/hede svn://192.168.1.200/hede.web .

That’s all!

sensimevanidus

24 March, 2010

JavaHL Library loading failure when working with Subclipse

Before reading further, please note that by the time this failure happened, I was using Eclipse 3.3.2 (Build id: M20080221-1800) with the Subclipse 1.6.10 plugin installed, on an Ubuntu 9.10 machine.

Eclipse kept giving the following error while working on a project checked out from an SVN repository:

Failed to load JavaHL Library.
These are the errors that were encountered:
no libsvnjavahl-1 in java.library.path
no svnjavahl-1 in java.library.path
no svnjavahl in java.library.path
java.library.path = /usr/lib/jvm/java-6-sun-1.6.0.15/jre/lib/i386/client::/usr/lib/jvm/java-6-sun-1.6.0.15/jre/lib/i386::/usr/lib/xulrunner-addons:/usr/lib/xulrunner-addons:/usr/java/packages/lib/i386:/lib:/usr/lib

This error message made me understand that an *svnjavahl* file had to be somewhere (except the paths of java.library.path property) on my machine to make everything work; so I made a search and got the result:

onur@ubuntulaptop:~$ sudo updatedb
onur@ubuntulaptop:~$ locate svnjavahl
/usr/lib/jni/libsvnjavahl-1.so
/usr/lib/jni/libsvnjavahl-1.so.0
/usr/lib/jni/libsvnjavahl-1.so.0.0.0

Et voila! I had to add /usr/lib/jni path to the java.library.path property. My way (which I don’t like) to do that is to declare it in eclipse.ini by adding this line:

-Djava.library.path=/usr/lib/jni

This made Eclipse run properly. By the way, my eclipse.ini content was:

onur@ubuntulaptop:~/eclipse$ cat eclipse.ini
-showsplash org.eclipse.platform
-vmargs
-XX:MaxPermSize=256m
-Xms40m
-Xmx256m
-Djava.library.path=/usr/lib/jni

That’s it!

(Note: To test whether JavaHL Client was working properly or not, I checked the SVN interface property at “Window -> Preferences -> Team -> SVN” in Eclipse.)