LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Fedora (https://www.linuxquestions.org/questions/fedora-35/)
-   -   how to execute java programs (https://www.linuxquestions.org/questions/fedora-35/how-to-execute-java-programs-4175440018/)

pradeep 1991 12-04-2012 11:49 AM

how to execute java programs
 
i wanted to execute java program so initially i used

YUM INSTALL JAVA
output: java already installed no updates found

then i wrote a java progrm and started compiling

javac <filename>
output:javac not found

when java is installed why a error with javac ?
help me

fatmac 12-04-2012 12:28 PM

Quote:

The Oracle implementation is packaged into two different distributions: The Java Runtime Environment (JRE) which contains the parts of the Java SE platform required to run Java programs and is intended for end-users, and the Java Development Kit (JDK), which is intended for software developers and includes development tools such as the Java compiler, Javadoc, Jar, and a debugger.
I don't use java, but the above might be a clue, you may need to download & install the JDK for your distro.
(To run a program, I think it is, java <progname>.jar.)

falcom 12-04-2012 02:17 PM

maybe you need a java compiler, try :
Quote:

yum install javacc

knudfl 12-04-2012 02:56 PM

# yum search java
.. And if you think you can use openjdk :
# yum install java-1.6.0-openjdk-devel
Or version 1.7 : # yum install java-1.7.0-openjdk-devel

The Sun java6jdk : jdk-1.6.0_37-fcs
32bits http://ftp.scientificlinux.org/linux...7-fcs.i586.rpm

64bits http://ftp.scientificlinux.org/linux...fcs.x86_64.rpm

Setting up java : Post # 4 here ..
http://www.linuxquestions.org/questi...-4175438243/#4

.


All times are GMT -5. The time now is 10:36 PM.