IMPORTANT: We are targeting the Indigo version of Eclipse.
Go to: http://www.eclipse.org/downloads/packages/release/indigo/sr2
You will be installing Eclipse IDE for Java EE Developers or Eclipse Classic. Select the download link appropriate for your version of Linux (32-bit vs. 64-bit)
Select the appropriate mirror and Save the file to your local machine making note of the location.
Open a Terminal and cd to the location where you saved the file.
Type the following command in the Terminal:
$ tar -zxvf eclipse-jee-indigo-SR2-linux-gtk-x86_64.tar.gz |
This will extract the 'eclipse' folder to this location.
If you are not happy with this location (in my case it's in Downloads) you can move it to a more convenient location
$ cd ~ $ mkdir Programs $ mv Downloads/eclipse Programs |
The above just creates a directory called Programs in your Home and moves the 'eclipse' folder and its contents to this new location.
Now we need to make it convenient to execute Eclipse.
$ su $ touch /usr/bin/eclipse $ chmod 755 /usr/bin/eclipse $ vi /usr/bin/eclipse |
We need to establish what our HOME directory is by entering the following into the Terminal:
$ echo $HOME |
The value returned back in my case is "/home/developer". In your case it would be "home/<username>". In the next step, ECLIPSE_HOME will be "HOME/Programs/eclipse".
Enter the following into the file:
#!/bin/bash export ECLIPSE_HOME="/home/developer/Programs/eclipse" $ECLIPSE_HOME/eclipse $* |
Save the file.
Back in the terminal, enter the following:
$ ln -s /usr/bin/eclipse /bin/eclipse $ vi /usr/share/applications/eclipse.desktop |
Enter the following into the file:
[Desktop Entry] Encoding=UTF-8 Name=Eclipse Comment=Eclipse IDE Exec=eclipse Icon=/home/developer/Programs/eclipse/icon.xpm Terminal=false Type=Application Categories=GNOME;Application;Development; StartupNotify=true |
The above simply creates a shortcut in Applications that you can use rather than always typing 'eclipse' in the Terminal to start Eclipse. Save the file.
Back in the Terminal, cd to the eclipse directory:
$ cd ~/Programs/eclipse $ chown -R developer:developer configuration/ $ exit |
The above simply prevents the "Invalid Configuration Location" error.
At this point, you have two ways to start Eclipse. Applications -> Eclipse Shortcut or you can simply type 'eclipse' in the Terminal.