LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Software (https://www.linuxquestions.org/questions/linux-software-2/)
-   -   Running a Java App on Linux (https://www.linuxquestions.org/questions/linux-software-2/running-a-java-app-on-linux-264606/)

sxa 12-09-2004 04:15 PM

Running a Java App on Linux
 
I have recently downloaded a piece of Amatuer Radio software that uses Java. I have never used Java before on linux, so I installed Java and it appears to be installed on my system.



Code:

stevex@maestro:~/JLog$ java -version
java version "1.4.2_04"
Java(TM) 2 Runtime Environment, Standard Edition (build 1.4.2_04-b05)
Java HotSpot(TM) Client VM (build 1.4.2_04-b05, mixed mode)

Using what the JLog (The program I am trying to install) Howto file I should have unpacked the file into a directory.. I did 'jar xv jl-1.02' inside the directory, and it unpacked the files..

Code:

stevex@maestro:~/JLog$ dir
Legal.txt  build.xml      contests/  foo          jl.bat  logs/
META-INF/  com/            data/      jl-1.02.jar  jl.sh  operations/
bin/      configuration/  docs/      jl-gen.bat  libx/  server.bat

According the Howto I should:

Quote:

On UNIX/Linux/OS X, type
'java JL'.
http://www.qsl.net/w1jq/HOWTO.txt

When I do that I get an error.. so I need to know if my error is a Java Error, or me doing somthing wrong. I understand that not many of you know about the program I am trying to install (or atleast I don't assume there are many hams on here) BUT I figure many of you know about Java, and I suppose its all about the same, atleast when getting things to run.

Code:

stevex@maestro:~/JLog$ java JL
Exception in thread "main" java.lang.NoClassDefFoundError: JL

Thats the error I get when I use the comman instructed by the HowTo.. I assume the howto is correct, and I am doing things correct.. and that that manes there is a Java error.. How do you I start the Java runtime enviroment to run apps?

Thanks for your time and help!

csfalcon 12-09-2004 05:09 PM

that is a java error. most likely the class JL is not in the default package. you have to track down which package by either
Code:

jar -t <jarfile>
or look at the source code. The package name is usually (com.something.something or java.something...)

once you find out run JL by
Code:

java <package>.JL

madluther 12-09-2004 05:16 PM

There's a startup script in the jl directory, to run it simply type in

Code:

sh jl.sh
HTH

Mad

sxa 12-09-2004 05:26 PM

If I was not born blonde..

Thanks.. I did sh jl.sh and now I have my program running..

Now for getting my other log program going which is in Java, but seems to be very different.

Thanks Again!


All times are GMT -5. The time now is 08:39 PM.