How To Ideas | How To Articles | How To Tutorials


1

How to install Eclipse in Linux


Eclipse is a an IDE i.e Integrated Development Environment tool mostly used by developers for JAVA development. This tool support development in a number of languages like C, C++, COBOL, Java, Perl, PHP, Python, Ruby, etc. and also supports plugins which can let you develop projects in a number of other languages as well.

Eclipse SDK is free and open source software released under the terms of the Eclipse Public License. In this tutorial, I will explain you how to install this IDE in your Linux based system. All the steps are successfully tested on Ubuntu 11.10 and Eclipse 3.7.1.

Instructions:

  1. Download Eclipse package from their website. You must select a version according to your need like if you want to develop C/C++ applications then you must select Eclipse IDE for C/C++ Developers, if you want to develop applications if JAVA, then you must select Eclipse IDE for JAVA Developers or Eclipse IDE for JAVA EE Developers and if you want to develop applications in third-party languages like Android from Google or some other language plugins, then you must select Eclipse Classic.
  2. Now open your Terminal application, move to the directory where you have downloaded eclipse archive using cd command and extract the package downloaded using the tar command. In my case the command is as follows
    tar xzf eclipse-SDK-3.7.1-linux-gtk.tar.gz
    Extract Eclipse

    Extract Eclipse

    Change the name of file eclipse-SDK-3.7.1-linux-gtk.tar.gz with the one you just downloaded.

  3. You can also extract the package by right clicking and then selecting Extract Here.
  4. After extracting, move the extracted directory to /opt/ directory/. After that change the owner of the directory to root using chown command recursively (by using -R option with chown command) and then add read permission to all the directories and files present in the Eclipse directory by using chmod command with -R option.
    sudo mv eclipse /opt/
    sudo chown -R root:root eclipse
    sudo chmod -R +r eclipse
    Move Eclipse to /opt/ Directory

    Move Eclipse to /opt/ Directory

    Change Permissions and Directory Owner

    Change Permissions and Directory Owner

  5. Now we need to create eclipse executable in /usr/bin/ directory with following commands and then we need to set its permissions to 755. Use the following command to create eclipse executable
    sudo gedit /usr/bin/eclipse

    Now place following command lines in the file opened in gedit

    #!/bin/sh
    #export MOZILLA_FIVE_HOME="/usr/lib/mozilla/"
    export ECLIPSE_HOME="/opt/eclipse"
    $ECLIPSE_HOME/eclipse $*

    After this use the following command to change executable file permission to 755

    sudo chmod 755 /usr/bin/eclipse

    Creating Eclipse Executable

    Creating Eclipse Executable

  6. Now we need to create Gnome menu item for eclipse. Use the following command to create eclipse.desktop file in /usr/share/applications/ directory
    sudo gedit /usr/share/applications/eclipse.desktop

    Paste in the following lines in that file and then save and quit gedit

    [Desktop Entry]
    Encoding=UTF-8
    Name=Eclipse
    Comment=Eclipse IDE
    Exec=eclipse
    Icon=/opt/eclipse/icon.xpm
    Terminal=false
    Type=Application
    Categories=GNOME;Application;Development;
    StartupNotify=true

    Create Gnome Menu Item

    Create Gnome Menu Item

  7. That’s all Eclipse is successfully installed in your system. You can launch it from command line using the following command
    /opt/eclipse/eclipse -clean &

 

Incoming search terms:

  • download sdk 7 for ubuntu for eclipse (1)
  • MEANING OF COMMAND IN LINUX sudo mv eclipse /opt/ (1)
Filed in: Eclipse, Linux/Unix, Ubuntu Tags: , , , , , , , ,

One Response to "How to install Eclipse in Linux"

  1. qmoney06 says:

    Thanks!

Leave a Reply

Submit Comment



© 5495 How To Ideas. All rights reserved.
Proudly designed by Theme Junkie.