> Hello all. I just installed the newest jdk rpm from
> /pub/contrib/hurricaine/i386 and I'm having problems. The javac
> compiler seems to work fine. However, when I try to run something using
>
> java program.class
>
> It won't let me. I'm pretty sure that the problem is my $CLASSPATH
> variable. When I installed the jdk, this variable was set to
>
> /usr/lib/jdk-1.1.5/lib/classes.zip
>
> What I need to do is change it to
>
> /usr/lib/jdk-1.1.5/lib/classes.zip:.
>
> so that the interpereter will look for programs in whatever directory
> I'm in. Does anybody know where this variable is set? Actually, for
> that matter, does anybody know where the default $PATH variable is set?
> (Yes, I'm a real newbie.) Thanks in advance.
>
> -Chris Lea
> [EMAIL PROTECTED]
First of all, I think you want to execute:
java program
not,
java program.class
If the CLASSPATH setting is really your problem, you could set it in
the appropriate dot file for your shell. There may be a more standard
place for it, but that will work. I use the tcsh shell (used it on
other Unices at work before getting Linux at home), but you are
probably using bash since I think that is the default RedHat Linux
shell. I'm not positive of the bash syntax since I use tcsh, but I
think put the following in your .bashrc file (in your home directory
should work):
CLASSPATH=/usr/lib/jdk-1.1.5/lib/classes.zip:.
export CLASSPATH
and then log out and back in or just execute:
source ~/.bashrc
Your standard path variable can be set using the same method. There
are system wide files that set these things (try looking at
/etc/profile), but you can modify them in your .bashrc file.
-Dave
[EMAIL PROTECTED]
--
PLEASE read the Red Hat FAQ, Tips, Errata and the MAILING LIST ARCHIVES!
http://www.redhat.com/RedHat-FAQ /RedHat-Errata /RedHat-Tips /mailing-lists
To unsubscribe: mail [EMAIL PROTECTED] with
"unsubscribe" as the Subject.