Java in Linux


Recommended Posts

What is the best Java IDE for Red Hat 7.2 - 9 ?

I used to use JCreator ( from www.jcreator.com ) but I switched to Linux, and if I am to stay with Linux I need to be able to write programs in Java.

What do you guys use? What do you find the best? easiest?

Link to comment
Share on other sites

Download http://download2.eclipse.org/downloads/dro...8-linux-gtk.zip.

$ cd
$ wget http://download2.eclipse.org/downloads/drops/S-3.0M8-200403261517/eclipse-SDK-3.0M8-linux-gtk.zip
$ unzip eclipse-SDK-3.0M8-linux-gtk.zip
$ cd eclipse
$ ./eclipse

It should run as long as you have a JDK >= 1.4 in your PATH. You can check that by running

$ java -version

If it says "bash: java not found" or something to that effect, come back here and we'll help you set it up.

Link to comment
Share on other sites

I do have the Java SDK 1.4.2_04 installed. I installed it yesterday and I was playing Java games online. I think my path is messed up, but I dunno. But Yes, I do get the bash: java not found error.

Link to comment
Share on other sites

Ok. Open up /etc/profile in your favorite text editor. At the very end of the file, add

JAVA_HOME=/opt/sun-j2sdk
export JAVA_HOME
PATH=$PATH:$JAVA_HOME/bin
export PATH

Just replace "/opt/sun-j2sdk" with the directory to which you installed the JDK (it should be somewhere in /opt). Finally

$ source /etc/profile
$ java -version

Everything should work fine then.

Edited by Mr. Static Void
Link to comment
Share on other sites

do I have to be logged in as root to change the file? I try to add those to lines to the top of the profiles file and it says that it can't write to the file. When I go to properties the permissions are blacked out.

Link to comment
Share on other sites

First off, you have to add those lines to the END of the profile. Second, you must be root to do it. You can temporarily become root by typing 'su' in the console. Do something like

$ su
Password:
# nano -w /etc/profile

Link to comment
Share on other sites

This topic is now closed to further replies.
  • Recently Browsing   0 members

    • No registered users viewing this page.