`
zhanglibin1986
  • 浏览: 374490 次
  • 性别: Icon_minigender_1
  • 来自: 北京
社区版块
存档分类
最新评论

Ubuntu10.10搭建Android开发环境

阅读更多
Installing the JDK

The Sun JDK is no longer in Ubuntu's main package repository. In order to download it, you need to add the appropriate repository and indicate to the system which JDK should be used.

Java 6: for Gingerbread and newer

$ sudo add-apt-repository "deb http://archive.canonical.com/ lucid partner"
$ sudo add-apt-repository "deb-src http://archive.canonical.com/ubuntu lucid partner"
$ sudo apt-get update
$ sudo apt-get install sun-java6-jdk


最后设置JAVA环境
ln -s /usr/lib/jvm/java-6-sun/bin/javac   /etc/alternatives/javac 
ln -s /usr/lib/jvm/java-6-sun/bin/java     /etc/alternatives/java

ln -s /usr/lib/jvm/java-1.5.0-sun/bin/javac   /etc/alternatives/javac 
ln -s /usr/lib/jvm/java-1.5.0-sun/bin/java     /etc/alternatives/java
sudo ln -s /usr/lib/jvm/java-1.5.0-sun/bin/javadoc /etc/alternatives/javadoc

$ sudo update-alternatives --config java
$ sudo update-alternatives --config javac
java -version
javac -version
分享到:
评论

相关推荐

Global site tag (gtag.js) - Google Analytics