Prior to installing the Java 2 SDK, you should insure that you have installed the full set of required patches needed for support of this release. You will find a patch cluster for each Solaris operating environment platform. Each patch cluster applies to all supported versions of the Java 2 Standard Edition (J2SE) on the given platform.
To install the 32-bit Java 2 SDK on either Intel or SPARC processors, follow the installation instructions below.
If you want to install the 64-bit Java 2 SDK on your SPARC platform, you must follow a two-step procedure. First, install the 32-bit Java 2 SDK using the installation instructions below. Second, install the supplemental support for 64-bit operation by following the 64-bit Installation Instructions.
J2SDK 1.4.0 is available in two installation formats.
.tar.Z file containing Solaris SUNW* packages to be installed with the pkgadd utility. Root access is required to install SUNW* packages. By default, SUNW* packages are installed in a location such that they replace the system version of the Java platform supplied by the Solaris operating environment. If you are using this bundle, see Installation of Packages below.Note: When installed in the default location, J2SDK 1.4.0 will overwrite and replace any previous installation of J2SDK 1.3.0 or J2SDK 1.3.1.
J2SDK 1.4.0 will not automatically become the default Java platform. To make J2SDK 1.4.0 the default Java platform, see the note on Selecting the Default Java Platform at the end of this file.
Note: For any lines on this page containing the following notation, you must substitute the appropriate Java 2 SDK update version number for the notation.
<version number>
For example, if you are downloading update 1.4.0_01, the following command:
chmod +x j2sdk-1_4_0_<version number>-solaris-sparc.sh
would become:
chmod +x j2sdk-1_4_0_01-solaris-sparc.sh
Installation of Self-Extracting Binary
Before you download a file, notice that its byte size is provided on the download page. Once the download has completed, check that you have downloaded the full, uncorrupted software file.
On SPARC processors: chmod +x j2sdk-1_4_0_<version number>-solaris-sparc.sh
On x86 processors: chmod +x j2sdk-1_4_0_<version number>-solaris-i586.sh
Launch the self-extracting binary file. The binary code license will be displayed, and you will be prompted to agree to its terms. The Java 2 SDK files will be installed in a directory called j2sdk1.4.0_<version number>.
Installation of Packages
Follow these instructions if you want to use the pkgadd utility to install the Solaris packages for the Java 2 SDK. If you want to use the self-extracting binary file instead, see Self-extracting Binary above.
Please note that there is a bug in the uninstall scripts associated with some of the Java 2 SDK packages. See the Release Notes for more information.
Before you download a file, notice that its byte size is provided on the download page. Once the download has completed, check that you have downloaded the full, uncorrupted software file.
On SPARC processors: zcat j2sdk-1_4_0_<version number>-solaris-sparc.tar.Z | tar -xf -
On x86 processors: zcat j2sdk-1_4_0_<version number>-solaris-i586.tar.Z | tar -xf -
This will create several packages (SUNWj3dmo, SUNWj3dev, SUNWj3man, SUNWj3rt, plus SUNWj3jmp containing Japanese man pages) along with the product license, README, and other release documentation.
su and entering the super-user password.On either x86 or SPARC processors:
pkgadd -d . SUNWj3rt SUNWj3dev SUNWj3man SUNWj3dmo
This will install the J2SDK 1.4.0 version into /usr/j2se; see the pkgadd(1) and admin(4) man pages for information on installing the SDK in a non-default location.
If you previously installed the man page packages from J2SDK 1.3.0 or 1.3.1, remove them.
pkgrm SUNWjej3m SUNWjpj3m SUNWjuj3m
Then run the pkgadd command to install the new Japanese man page package:
pkgadd -d . SUNWj3jmp
Java Plug-in Product Installation Instructions
NPX_PLUGIN_PATH environment variable to the directory containing the javaplugin.so file. (This step is not necessary if you use only Netscape 6.x browsers.)On the SPARC operating environment, the default location of javaplugin140.so for the package installation is in this directory: /usr/j2se/jre/plugin/sparc/ns4/
On Intel platforms, the default loscation is this directory: /usr/j2se/jre/plugin/i386/ns4/
javaplugin.so) should be given with an absolute path—not relative to the installation location of the JRE.NPX_PLUGIN_PATH will override the default search path used by the browser. Therefore any plugin directories that the browser currently searches for plugins should also be added to the path.Java 2 SDK, Standard Edition Version 1.4.0 Solaris Operating Environment
Notes:
regxpcom, as described below, first shut down the browser.setenv LD_LIBRARY_PATH <Netscape 6>:$LD_LIBRARY_PATHIf you do not add Netscape to your LD_LIBRARY_PATH you are likely get an error when you run regxpcom. The message will say that Open failed: No such file or directory.
If and only if you are using Netscape 6, you will need to use regxpcom provided by Netscape to register the libjavaplugin_oji140.so file. In the package installation of 1.4.0, copies of this file are located at /usr/j2se/jre/plugin/<arch>/ns600/libjavaplugin_oji140.so and /usr/j2se/jre/plugin/<arch>/ns610/libjavaplugin_oji140.so, where <arch> is either sparc or i386, depending on your platform. For example:
cd ${NETSCAPE6}/bin
If you use a Netscape 6.0x browser:
regxpcom ${JRE}/plugin/sparc/ns600/libjavaplugin_oji140.so
If you use a Netscape 6.1x browser:
regxpcom ${JRE}/plugin/sparc/ns610/libjavaplugin_oji140.so
After running the regxpcom command you should get a message saying that registration was successful for <jre>/plugin/sparc/ns610/libjavaplugin_oji140.so
If regxpcom does not register the Java Plug-in successfully i.e., you get a registration-failed message or a core dump try creating a link to the Java Plug-in libjavaplugin.so file in the Netscape 6 plugins directory.
cd <Netscape 6>/plugins
ln -s <JRE>/plugin/sparc/ns610/libjavaplugin_oji140.so .
Be sure to include the period at the end.
Note: Only one Java Plug-in can be registered at a time. When you want to use a different version, unregister the one you have and register the new version.
regxpcom -u <absolute path to Java Plug-in libjavaplugin.so file>
Example:
regxpcom -u ${JRE}/plugin/sparc/ns610/libjavaplugin_oji140.so
regxpcom ${JRE}/plugin/sparc/ns610/libjavaplugin_oji141.so
In Netscape do Help -> About Plug-ins to confirm that the Java Plug-in is loaded.
Java Web Start Product Installation Instructions
J2SDK 1.4.0 includes the Java Web Start product. Inside the J2SDK's jre directory you will find a ZIP file named javaws-1_0_1_02-solsparc-int.zip on SPARC platforms and javaws-1_0_1_02-solx86-int.zip on Intel platforms. Move this file to a location where you want to install the Java Web Start product (preferably outside the Java 2 SDK installation). Unzip the file. One of the files extracted will be install.sh. Run this script to install the Java Web Start product.
jre/lib/sparc/client/libjvm.so (on SPARC )
jre/lib/i386/client/libjvm.so (on x86 platforms)
jre/lib/sparc/server/libjvm.so (on SPARC)
jre/lib/i386/server/libjvm.so (on x86)
Selecting the Default Java Platform
/usr/java/usr/java1.1/usr/java1.2/usr/j2se
Prior to the Solaris 8 release, the /usr/java symbolic link pointed to /usr/java1.1 if both JDK 1.1 and J2SDK 1.2.2 were installed, making JDK 1.1 the default Java platform. Starting with the Solaris 8 release, the /usr/java symbolic link points to /usr/java1.2 by default if both JDK 1.1 and J2SDK 1.2.2 are installed, making J2SDK 1.2.2 the default Java platform.
Because there are symbolic links in /usr/bin (also known as /bin) that use /usr/java (for example, /usr/bin/java refers to /usr/java/bin/java), this /usr/java link can change the default Java installation seen by most users. Many Java applications run on any of J2SDK 1.4.0, J2SDK 1.3.1, J2SDK 1.2.2, or JDK 1.1, but users and applications might want to be selective about which Java installation they use.
If you want to use JDK 1.1, /usr/java1.1/bin should be on your PATH before /usr/bin. If you want to use J2SDK 1.4.0, /usr/j2se/bin should be on your PATH before /usr/bin.
It is possible for root users to make J2SDK 1.4.0 the default Java platform by modifying the /usr/java symbolic link to point to /usr/j2se. However, changing the symbolic link in this manner may cause problems for some Java applications that are expecting to use earlier versions of the Java platform. See the online compatibility documentation for information about incompatibilities between J2SDK 1.4.0 and earlier releases.