Sunday, October 21, 2012

Install Eclipse 3.8.1 in Ubuntu 12.10


Eclipse is a very popular IDE for almost all purposes. Although the Ubuntu Software Center lets you install Eclipse with one click, many users like to do a manual installation instead. Also, at the time of this post, the Software Center still offers Eclipse 3.8.0, so if you want to install an up-to-date version, you have to choose the manual way. This is how it's done:
  1. Make sure you have installed a Java JDK (search for "java" in the Software Center).
  2. Download an Eclipse SDK archive that fits your machine's architecture (x86 for 32 bit, x86_64 for 64 bit).
  3. Navigate to the downloaded archive and extract it. You should get a folder named "eclipse".
  4. Open a terminal and type "sudo mv /path/to/eclipse /opt" and enter your password when prompted. Now the extracted folder is moved to your system-wide /opt folder.
  5. Final Step: creating a desktop shortcut. Type "gksudo gedit /usr/share/applications/eclipse.desktop". Enter your password when prompted. An editor window is opened. Insert the following:

    [Desktop Entry]
    Name=Eclipse 3.8
    Comment=Java IDE
    Exec=/opt/eclipse/eclipse
    Icon=/opt/eclipse/plugins/org.eclipse.sdk_3.8.1.v201209141540/eclipse256.png
    Type=Application
    Categories=Development

    Save the file and exit the editor. Now you can start eclipse using the dash.
You can install other versions the same way, just download the archive you want. For example, the current official version 4.2 is available under http://www.eclipse.org/downloads/. I prefer the 3.x series, as it is less resource-hungry and responds quicker. You even can have two or more versions of Eclipse at the same time, as each installation only operates inside its folder. Just remember to rename the install folders accordingly.

No comments:

Post a Comment