Jump to content

[guide] Install java 7 on Debian-based systems


llbranco

Recommended Posts

A quick how-to install Oracle’s JAVA 7 on Debian 7 or based (including Debian 7 kfreebsd)
 
First make sure the system is up-to-date:
apt-get update
apt-get upgrade
apt-get dist-upgrade
 
must to be root or sudo
(if you isn't root use sudo before each command, like "sudo apt-get update")
 
first, edit your source.list 
nano /etc/apt/source.list
 
add this lines on the end of file:
#sid
deb http://cdn.debian.net/debian/ sid main non-free contrib
deb-src http://cdn.debian.net/debian/ sid main non-free contrib
 
then update your apt and install java7 (jre and jdk)
apt-get update
apt-get install openjdk-7-jre openjdk-7-jdk
 
 
edit your source.list 
nano /etc/apt/source.list
 
comment or remove this lines on the end of file:
(or your system can be updated to somekind of unstable/beta)
(f you want to use Debian Sid (the beta/unstable version) keep it)
(I'm not responsible for any damage caused if you want to keep these lines after this point, till here it's safe)
#sid
deb http://cdn.debian.net/debian/ sid main non-free contrib
deb-src http://cdn.debian.net/debian/ sid main non-free contrib
 
so let's update your apt again
apt-get update
 
make your java 7 default
update-alternatives --config java
There are 2 choices for the alternative java (providing /usr/bin/java).
 
  Selection    Path                                            Priority   Status
* 0            /usr/lib/jvm/java-7-openjdk-kfreebsd-amd64/jre/bin/java   1071      modo automático
  1            /usr/bin/gij-4.7                                          1047      modo manual
  2            /usr/lib/jvm/java-7-openjdk-kfreebsd-amd64/jre/bin/java   1071      modo manual
 
just make sure to set jre or jdk 1.7 in my case i set "0" (ZERO)
 
checking your java version (if you get > 1.5 contrat's you can run and play Pokemmo on your debian based system)
java -version
[spoiler]
java version "1.7.0_25"
OpenJDK Runtime Environment (IcedTea 2.3.12) (7u25-2.3.12-4)
OpenJDK 64-Bit Server VM (build 23.7-b01, mixed mode)
[/spoiler]
 
you can (also) test your java version here:
http://javatester.org/version.html
Link to comment
  • 1 year later...

I found a link that tells me how to put a Debian APT on my iphone, if I install java 7 on it, would it work? I'm not very good with these kinds of things but I'm really curious. Any help to get this game on my iphone is appreciated!

Link to comment
  • 4 weeks later...
  • 2 weeks later...
Guest
This topic is now closed to further replies.
×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use and Privacy Policy.