How to SetUp Eclipse on Mac machine to run Java Programs

Dear Friends,

In this tutorial we will see how to setup Eclipse on Mac machine to run Java programs.So here are the steps :

My Operating System : OS X EI Capitan

1) Download latest stable version of Eclipse,which is Eclipse Mars  from following link

Note : You can download the earlier versions also.Below is the link which has hyperlinks to all eclipse versions

2) Unzip the downloaded file and we will see the eclipse application Icon placed at the same location where we downloaded the eclipse tar.gz file.

3) Now we need to install JDK.The latest version is JDK 1.8.

2.1) Download JDK 1.8 from below link

We need to download  jdk-8u91-macosx-x64.dmg from below options for Mac.

2.2 ) After downloading/saving jdk-8u91-macosx-x64.dmg file on system,we need to install JDK,for that double click on jdk-8u91-macosx-x64.dmg  and we will see following screen

2.3) As mentioned in above screen shot double click on the icon and we will get following screen

2.4) Click on Continue and we will see following screen

2.5) Click on Install and your installation will be done automatically and finally we will get following screen with success message

3) Now open your Eclipse by double clicking on eclipse icon that got created after extraction of.tar.gz file and give the location wherever you want to create workspace and click ok.

4) You will get following screen.

5) Close welcome screen and create a new Java Project by selecting File->New-> Project.. ->Java  Project. Give any name to project for example FirstMacProject and click Finish.

6) You will  get following screen

7) Create a package with name "in.blogspot.javaSolutionsGuide" and create a class with name "MyFirstMacClass".Add sysout with "Hello Mac" message in it.

8) Right Click on java file and select Run as -> Java Application

9) You will see output "Hello Mac" on console

 So with this we learnt how to setup Eclipse to run Java program on Mac machine.

 Thanks for reading !!!