To install JRE6 u12 as the default Java for the system, simply run the following two commands:
sudo update-alternatives --install "/usr/bin/java" "java" "/opt/java/jre1.6.0_12/bin/java" 1
sudo update-alternatives --set java /opt/java/jre1.6.0_12/bin/java
Following the execution of both commands, there should be output along the lines of:
Using '/opt/java/jre1.6.0_12/bin/java' to provide 'java'