Sunday, October 29, 2006

JDK

Downloaded and installed "jdk-1_5_0_09-linux-i586.rpm" , when type java in Terminal, the following message came-out:
libgcj-java-placeholder.sh

This script is a placeholder for the /usr/bin/java
master link required by jpackage.org conventions. libgcj's
rmiregistry, rmic and jar tools are now slave symlinks to these
masters, and are managed by the alternatives(8) system.

This change was necessary because the rmiregistry, rmic and jar tools
installed by previous versions of libgcj conflicted with symlinks
installed by jpackage.org JVM packages.
Usage: gij [OPTION] ... CLASS [ARGS] ...
to invoke CLASS.main, or
gij -jar [OPTION] ... JARFILE [ARGS] ...
to execute a jar file
Try `gij --help' for more information.

I have to remve libgcj and related dependencies:
# rpm -e gcc-java-3.4.2-6.fc3.i386
# rpm -e libgcj-devel-3.4.2-6.fc3.i386
# rpm -e libgcj

Finally, I have to update /etc/profile:
  1. Edit /etc/profile,add the text:
    PATH=$PATH:/usr/java/jdk1.5.0_03/bin
    export JAVA_HOME=/usr/java/jdk1.5.0_03
    export CLASSPATH=$JAVA_HOME/lib:.

  2. Make the new profile take effect:
    source /etc/profile
Now, the JDK set corrective.
[root@localhost ~]# java -version
java version "1.5.0_09"
Java(TM) 2 Runtime Environment, Standard Edition (build 1.5.0_09-b03)
Java HotSpot(TM) Client VM (build 1.5.0_09-b03, mixed mode, sharing)

===========================================================
I want to know if my modification correct or not?
Is it any other method which no need erase libgcj? Or, any side effect caused by erasing of libgcj?