Recently i have had the pleasure to set up my development environment from scratch.
I thought i would take a few moments to blog down how one can set up ones eclipse to work with Maven and Subversion.
First of all you will need to download maven from http://maven.apache.org/start/download.html
You will also need SVN on your machine.
Set MAVEN_HOME in your environment
Set JAVA_HOME in your environment (if not already set)
Download eclipse from http://www.eclipse.org/downloads/index.php
Now you will need to add the maven plugins.
To do this from within eclipse, you will need to go to the help menu and select 'Software Updates | Find and install'. From the resulting dialog click
on 'New Remote Site' to add the following url http://mevenide.codehaus.org/release/eclipse/update/site.xml. Follow the instructions to download both the maven and mavenide plugins
After this you will need to add the subversion plugin. Follow the same steps as for the maven plugins above but instead use the following url: http://subclipse.tigris.org/update. Follow the instructions to download the
subversion subclipse plugins.
"Note: As of Subclipse 0.9.14, we no longer ship native libraries (libsvnjavahl) for the Linux and OSX versions. The Win32 version still includes the native libraries. OSX users can use the excellent Metissian packages to obtain the required libraries (including the entire subversion installation). Linux users will either have to build their own, or pester their packager to include the SVN javahl subsystem with their build."
I found that the easiest way to overcome the above limitation on a debian system is to use apt-get to install a pre-compiled binary. You will first need to add the following source to your sources.list
'deb http://www.ggtools.net/files/debian/unstable/ ./'
Then you will need to execute the following commands.
sudo apt-get update
sudo apt-get install libsvn-javahl
sudo ln -s /usr/lib/libsvnjavahl-1.so /../eclipse/plugins/org.tigris.subversion.subclipse.core_0.9.29/libsvnjavahl.so
The above worked fine for me.
Now you will notice that if you right click on the project name (within package explorer) you will get a maven entry in the drop down menu.
Hint: Use the POM Synchronizer to add the jars from the maven repository to your project class path.
Posted by michaelm at March 8, 2005 08:34 AM | TrackBack