Solved

Where do I put java classes in Suse 7.1 ?

Posted on 2001-09-07
5
252 Views
Last Modified: 2012-05-04
I am running Suse 7.1 (uname -a = 'Linux linux 2.2.18 #1 Wed Jan 24 12:28:55 GMT 2001 i686 unknown') and have downloaded a java application to run. Having unzipped and untarred it and attempted to run it (java TimeTrack-1.0.jar), I am told "Can't find class TimeTrack-1.0.jar". Do I need to place the jar file in a particular directory or do I need to tell java where the jar exists ?

Cheers

Matt
0
Comment
Question by:paninaro
  • 2
5 Comments
 
LVL 2

Expert Comment

by:dirc
ID: 6464874
You may just need to change the way you invoke java. Try:

java -jar TimeTrack-1.0.jar

This should work if TimeTrack-1.0.jar has a manifest that specifies the initial class to load, and if you are using java 1.2 or better. You can determine the version of java you have using with:

java -version

If that does not work, check the documentation for the name of the initial class to load. Then try:

java -cp ${CLASSPATH}:<path to dir>/TimeTrack-1.0.jar class.to.load



0
 

Author Comment

by:paninaro
ID: 6464982
I'm using java version 1.1.8. Is this particularly old ? It doesn't seem to support either the -jar or the -cp options. I tried using the -classpath option to do:
   
   java -classpath /home/matt/downloads/web/TimeTrack/TimeTrack-1.0.jar TimeTrack.class

However that then gives a:
   Unable to initialize threads: cannot find class java/lang/Thread

error.
0
 
LVL 2

Accepted Solution

by:
dirc earned 100 total points
ID: 6465041
Java 1.1.8 is about two years old. You probably need to added the classes.zip file to your classpath.

java -classpath <path_to_java_home>/lib/classes.zip:/home/matt/downloads/web/TimeTrack/TimeTrack-1.0.jar TimeTrack.class

If you are not sure where you java home is, use "which java" to find it.
0
 
LVL 20

Expert Comment

by:jmcg
ID: 9916250
No comment has been added lately, so it's time to clean up this TA.
I will leave the following recommendation for this question in the Cleanup topic area:

Accept: dirc {http:#6465041}

Please leave any comments here within the next seven days.
PLEASE DO NOT ACCEPT THIS COMMENT AS AN ANSWER!

jmcg
EE Cleanup Volunteer
0

Featured Post

Master Your Team's Linux and Cloud Stack

Come see why top tech companies like Mailchimp and Media Temple use Linux Academy to build their employee training programs.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Have you ever been frustrated by having to click seven times in order to retrieve a small bit of information from the web, always the same seven clicks, scrolling down and down until you reach your target? When you know the benefits of the command l…
The purpose of this article is to demonstrate how we can upgrade Python from version 2.7.6 to Python 2.7.10 on the Linux Mint operating system. I am using an Oracle Virtual Box where I have installed Linux Mint operating system version 17.2. Once yo…
This video shows how to quickly and easily add an email signature for all users on Exchange 2016. The resulting signature is applied on a server level by Exchange Online. The email signature template has been downloaded from: www.mail-signatures…
This video shows how to use Hyena, from SystemTools Software, to bulk import 100 user accounts from an external text file. View in 1080p for best video quality.

856 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question