LinuxQuestions.org
Share your knowledge at the LQ Wiki.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices


Reply
  Search this Thread
Old 03-21-2010, 12:45 PM   #1
kushwaha.naveen
LQ Newbie
 
Registered: Mar 2010
Posts: 1

Rep: Reputation: 0
writing and compiling java program in fedora 12


how we can we write java programs in java and how we execute it.. to produce output?
 
Old 03-21-2010, 04:36 PM   #2
btmiller
Senior Member
 
Registered: May 2004
Location: In the DC 'burbs
Distribution: Arch, Scientific Linux, Debian, Ubuntu
Posts: 4,275

Rep: Reputation: 370Reputation: 370Reputation: 370Reputation: 370
You can write the program in any text editor. To compile it, you'll need a Java compiler. I haven't done serious Java development in years. When I did, I just downloaded the Java SDK from Sun, but nowadays the GNU compilers can also compile Java. You can also install an IDE like Eclipse or NetBeans, If you need more information than this, you need to ask a more specific question. Good luck!
 
Old 03-21-2010, 04:44 PM   #3
devnull10
Member
 
Registered: Jan 2010
Location: Lancashire
Distribution: Slackware Stable
Posts: 548

Rep: Reputation: 116Reputation: 116
You should download and install the JDK from sun. Then write your files in your favorite text editor and compile using the "javac" command. Commands also exist for wrapping into jar files.
Then execute using the "java" command.

You may need to set up your classpath too - either though your .bashrc or directly to the java/c programs as an argument (javac -classpath . myfile.java) etc.
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Writing a C program that interacts with Java Ymir Programming 1 03-01-2009 11:34 PM
how to avoid writing every methods for a listener in a java program ?? alred Programming 2 05-24-2006 11:41 PM
program for writing/compiling C++ in Fedora klmbrt Linux - Newbie 10 01-26-2005 07:58 AM
compiling a java program on server using servlet? raghutv Programming 1 03-15-2003 07:17 AM
Whats the best, free, program for writing and running Java oudent Programming 8 12-08-2001 07:18 AM


All times are GMT -5. The time now is 03:05 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration