How to install Eclipse IDE on Ubuntu 20.04

eclipse Is one of the most popular open source IDEs (IIntegration ddevelopment of EEnvironment) for use by software developers. It is popular in Java-based applications and is also used in C/C++, PHP and Perl and other web projects.

Eclipse is very powerful Integrated Development Environment Support multiple programming languages. It provides many plug-ins and extensions to enhance the functions of Eclipse, such as source code version control (git, svn), class diagram generator, GUI builder.

This tutorial will show you two ways to install Eclipse on an Ubuntu 20.04 LTS machine.

prerequisites

In order to install the Eclipse IDE, you must Install JRE (Java Runtime Environment) On your Ubuntu machine:

$ sudo apt update
$ sudo apt install openjdk-14-jre

To verify that Java has been successfully installed, let’s run:

$ java --version

Output:

openjdk 14.0.1 2020-04-14
OpenJDK Runtime Environment (build 14.0.1+7-Ubuntu-1ubuntu1)
OpenJDK 64-Bit Server VM (build 14.0.1+7-Ubuntu-1ubuntu1, mixed mode, sharing)

Install Eclipse via the installer package [Method 1]

At the time of writing, The latest version The name of Eclipse is: Eclipse IDE 2020-06. Eclipse can be downloaded from its official website https://www.eclipse.org/downloads/ through a browser.

By default, the installer package is downloaded to the directory “~/Downloads” named “eclipse-inst-linux64.tar.gz”.

Or by using the wget command as follows:

$ wget https://download.eclipse.org/oomph/epp/2020-06/R/eclipse-inst-linux64.tar.gz

Let us unzip the downloaded tarball file to the directory “/opt” by running the following command:

$ sudo tar -xf eclipse-inst-linux64.tar.gz -C /opt

Eclipse installer: eclipse-inst

In order to install Eclipse, start the installer file “eclipse-inst” by running the following command:

$ cd /opt/eclipse-installer
$ sudo ./eclipse-inst

The Eclipse package window appears, let us choose your favorite package IDE.

Eclipse installer window

For example, select Eclipse IDE for C/C++ developers and click INSTALL.

Eclipse IDE for C/C++ developers

Next, you must accept the Eclipse Foundation Software User Agreement.

Eclipse Software User Agreement

Now, your Eclipse IDE will be installed.

Install Eclipse

After the installation is complete, you can start Eclipse.

Quickly install Eclipse [ Method 2]

Install Eclipse via card The package manager is the most convenient installation method to introduce the Eclipse integrated development environment to an Ubuntu computer.

$ sudo snap install --classic eclipse

In order to install an older version of Eclipse, you can use the apt package manager:

$ sudo apt install eclipse

Another easy way to install the Eclipse IDE is to use the Ubuntu Software Center. Let’s open the Software Center, search for Eclipse, and click the “Install” button.

Create launcher icon

After successfully downloading and installing Eclipse, you may need to create a shortcut to Start your IDE. Use your favorite editor to create a file named “eclipse.desktop” and enter the following lines in it:

[Desktop Entry]
Name=Eclipse
Type=Application
Exec=/opt/eclipse/eclipse
Terminal=false
Icon=/opt/eclipse/icon.xpm
Comment=Integrated Development Environment
NoDisplay=false
Categories=Development;IDE;
Name[en]=Eclipse
Name[en_US]=Eclipse

Please note that the path in the “Exec =” and “Icon =” lines depends on your system. You can find the path in the execution line by running the following command:

$ which eclipse

Now, enable the launcher icon:

$ sudo chmod +x eclipse.desktop
$ sudo mv eclipse.desktop /usr/share/applications/eclipse.desktop

that’s it. From now on, you can search for Eclipse and launch it in the Applications Center on the Ubuntu machine.

in conclusion

In this tutorial, we learned how to install Eclipse IDE on Ubuntu 20.04. Now you can start writing your own code to create many great applications using Eclipse.

Thank you for reading, please leave your suggestions in the comments section below.

Sidebar