Course:COSC111/EclipseInstall

From UBC Wiki

Installing The Eclipse IDE

Java comes in two flavours: The JRE (Java Runtime Environment) and the JDK (Java Development Kit). The JRE allows programs written in Java to run on your computer while the JDK allows you to create new applications written in Java.


Windows XP/Vista/7 (x86/x64)

Most Windows PCs have the JRE pre-installed. However, in order to create Java programs on your computer, you will need to install the JDK.

  • Uninstall any versions of Java which may be installed. You can uninstall programs from the control panel.
  • Download the JDK from Oracle's website and double-click on the downloaded file to install the JDK. Follow the on screen instructions and select the default values.
  • Obtain the Eclipse IDE from the Eclipse website. Be sure to select the Eclipse IDE for Java Developers version. The file will download as a ZIP file.
  • Eclipse does not use an installer; simpliy unzip the ZIP file containing the ZIP file into your C:\ drive. The Eclipse program files will be stored in the folder named C:\eclipse.
  • On your desktop, create a shortcut to the file named eclipse.exe. Once created, double-click on the shortcut and Eclipse will launch.


Mac OSX

An installation guide is required for this operating system.


Linux

  • Most distributions of Linux contain gcj (GNU Compiler for Java). Unfortunately, Eclipse is not yet 100% compatible with gcj, so the best solution is to install the Oracle JDK by downloading the self-extracting script from Oracle's website. When selecting the appropriate JDK, ensure you do not download the RPM version.
  • Install the JDK as the root user and create a symbolic link for convenience.
$ su -
# cd /usr/local
# sh /path/to/jdk-6u21-linux-i586.bin
# ln -s jdk1.6.0_21 java

For Ubuntu users, you may require the use of the sudo command

$ cd /usr/local
$ sudo sh /path/to/jdk-6u21-linux-i586.bin
$ sudo ln -s jdk1.6.0_21 java
  • Download the gzipped tarball of Eclipse from the Eclipse website and extract the file into the /usr/local directory as the root user. Ensure that you download the Eclipse IDE for Java Developers version.
$ su -
# cd /usr/local
# tar zxf /path/to/eclipse-SDK-3.6.1-linux-gtk.tar.gz

For Ubuntu users, you may require the use of the sudo command

$ cd /usr/local
$ sudo tar zxf /path/to/eclipse-SDK-3.6.1-linux-gtk.tar.gz
  • You may start Eclipse from the command line as follows, or create an application launcher.
$ /usr/local/eclipse/eclipse -vm /usr/local/java/bin/java