Execution of java and javac commands

Mehdi Hassanpour mehdi.public at gmail.com
Tue Dec 6 06:42:49 UTC 2005


edit your `/etc/profile' file and set the PATH for your java home and java
binary directory in that

add something like this:

export JRE_HOME=/usr/java/jre1.5.0_05
export PATH=$PATH:$JRE_HOME/bin

edit it for your self


On 12/6/05, Alfred Vahau <Alf.Vahau at upng.ac.pg> wrote:
>
> I have installed the j2sdk1.4.2_10 Java binary on my Ubuntu system (Warty)
> and made a symbolic to the java and javac commands in /usr/bin/java and
> /usr/bin/javac. /usr/bin is on the PATH environment. Where I issue the *which
> java* command, it returns a blank line. When I issue *whereis java
> *it returns a positive output: *java: /usr/bin/java
>
> *I conclude that the output of the *which* command is an acknowledgement
> of the path being correct. For instance, I can issue *which perl* and get
> the result
> /usr/bin/perl so the perl command is on the system path.
>
> The java symbolic links are soft links  and created thus
>
> ln -s /usr/local/bin/j2sk1/4/2_10/bin/java /usr/bin/java
> ln -s /usr/local/bin/j2sk1/4/2_10/bin/java /usr/bin/javac
>
> The java binary file (with extension bin) was unpacked in the
> /usr/local/bin directory.
> How can I get the system to recognize that java and javac are on the
> environment path? I have tried rebooting (I didn't think this was necessary
> but tried anyway and it didn't make a difference.) For noting the execution
> of the *java* command is successful when I am in the directory containing
> the command and issuing a command for an example like so:
>
> ./java -jar SampleTree.jar
>
> and I get a window with the demonstrated output.
>
> Thanks in advance for any pointers.
>
> Alfred,
>
>
> --
> ubuntu-users mailing list
> ubuntu-users at lists.ubuntu.com
> http://lists.ubuntu.com/mailman/listinfo/ubuntu-users
>
>
>


--
==================================================
Yours Sincerely, Mehdi Hassanpour
----------------------------------------------------------------------
/* Of one Essence is the human race,
Thusly has Creation put the Base;
One Limb impacted is sufficient,
For all Others to feel the Mace.
                           ~Saadi (persian poet) -1258 */
----------------------------------------------------------------------
http://ImPersian.com     |     http://Hezardastan.org
==================================================
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.ubuntu.com/archives/ubuntu-users/attachments/20051206/58f113cc/attachment.html>


More information about the ubuntu-users mailing list