Install the Java environment In debian-general Linux technology-Linux programming and kernel information. The following is a detailed description. Abstract:
This document is a reference document for installing Java Development Kit (JDK/J2SDK) On Debian GNU/Linux systems.
Due to license issues, SUN's Java system cannot be provided directly in Debian. Therefore, the method for installing Java is provided here for your reference.
1. Get sun's JDK
You can choose to download from Java official: http://java.sun.com or another website
JRE (J2RE)
Java Runtime Environment-if you do not want to create a Java application by yourself, just install it.
JDK (J2SDK)
Java Development Kit-Java software open tool. If you need to create your own Java application, you need to select JDK.
The latest version is:
JDK: jdk-1_5_0_06-linux-i586.bin
JRE: jre-1_5_0_06-linux-i586.bin
Note: The SDK already contains the JRE. JDK is used as an example below.
2. Build a Packaging Environment
Fortunately, Debian provides us with the SDK's DEB package build tool: java-package
# Apt-get install-u java-package fakeroot
Note: update the package list before installation.
3. Create a. deb Software Package
Run as a common user:
$ Fakeroot make-jpkg jdk-1_5_0_06-linux-i586.bin
In this process, there may be some warning information and some necessary options. After a few minutes, the prompt that the software package is successfully created should appear. Congratulations, you will find something similar in the current directory:
Sun-j2sdk1.5_1.5.0 + update06_i386.deb
Software Package
4. Installation
Switch to the root user and run the following command:
# Dpkg-I sun-j2sdk1.5_1.5.0 + update06_i386.deb
Of course, you should specify the correct software package name as needed. This is easy to do. Check the current directory.
5. Configure the environment
In/etc/profile (or ~ /. Bashrc) Add the following content to the script file:
9. Culture Install Chinese fonts: Create the fallback directory under the $ JAVA_HOME/jre/lib/fonts/directory. Copy the Chinese font (for example, simsun. ttf) to this directory.
The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion;
products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the
content of the page makes you feel confusing, please write us an email, we will handle the problem
within 5 days after receiving your email.
If you find any instances of plagiarism from the community, please send an email to:
info-contact@alibabacloud.com
and provide relevant evidence. A staff member will contact you within 5 working days.