Java is now available as package in the non-free repository :
apt-get install sun-java5-jreapt-get intall sun-java5-jdkThe debian package java-package is an utility for building Java(TM) 2 related Debian packages from the binary distribution (from sun or blackdown) :
Install the java-package:
apt-get install java-package debhelper fakeroot
Download the wanted j2re or j2sdk on the java.sun.com site.
Create the package
fakeroot make-jpkg <downloadedfile.bin>
Install the obtained debian package:
dpkg -i obtained_debian_package.deb
If you have dependency problems, check you’re using the latest release and you’re using the right distribution (testing / unstable, etc ..).