In this tutorial we’ll learn how to install Eclipse on CentOS 7. We will also install and configure its prerequisites. Eclipse is an open-source development environment used to develop applications. It supports various programming languages and can be installed on all Operating systems (Windows, Linux, Mac).
I recommend to use a minimal CentOS server setup as a basis for the tutorial, that can be a virtual or a root server image with an CentOS 7 minimal install from a web hosting company or you use our minimal server tutorial to install a server from scratch.
Install Eclipse on CentOS 7
Step 1. First, ensure your system and apt package lists are fully up-to-date by running the following:
yum -y install epel-release yum -y update
Step 2. Installing Java.
Eclipse requires Java to be available on your machine. So, go and install the Java:
yum install java
Check if java installed:
Step 3. Installing Eclipse.
First, You can download required IDE from its official website. (I have download Eclipse IDE for Java EE developers. You have other options available on download page)
Step 4. Configure Eclipse IDE.
I assume you have downloaded Eclipse source code (eclipse-jee-oxygen-2-linux-gtk-x86_64.tar.gz) Extract the Eclipse archive file under /usr/local directory.
tar -zxvf eclipse-jee-oxygen-2-linux-gtk-x86_64.tar.gz -C /usr/local/
Then, Simply create an eclipse binary symbolic link to make it accessible system-wide:
ln -s /usr/local/eclipse/eclipse /usr/bin/eclipse
Step 5. Create Eclipse Launcher Icon.
In this step create a desktop launcher for the Eclipse. Simply create an eclipse.desktop file on your system at below location:
Add the entry to file and save it:
[Desktop Entry] Name=Eclipse Comment=Eclipse IDE Type=Application Encoding=UTF-8 Exec=/usr/bin/eclipse Icon=/usr/local/eclipse/icon.xpm Categories=GNOME;Application;Development; Terminal=false StartupNotify=true
Now search the Eclipse in GNOME search, You will find the icon as below: