1. 安裝所有的套件
sudo apt-get install git-core gnupg flex bison gperf build-essential zip curl libc6-dev libncurses5-dev:i386 x11proto-core-dev libx11-dev:i386 libreadline6-dev:i386 libgl1-mesa-dev:i386 g++-multilib mingw32 openjdk-6-jdk tofrodos python-markdown libxml2-utils xsltproc zlib1g-dev:i386
2 . gcc 降級
sudo apt-get install gcc-4.4 g++-4.4 g++-4.4-multilib
sudo rm /usr/bin/gcc
sudo rm /usr/bin/g++
sudo ln -s /usr/bin/gcc-4.4 /usr/bin/gcc
sudo ln -s /usr/bin/g++-4.4 /usr/bin/g++
3 . 安裝 Sun Java 6
先上官網 Download Java http://www.oracle.com/technetwork/java/javase/downloads/ 點擊開啟連結
以 jdk-6u38-linux-x64.bin 為例
jdk-6u38-linux-x64.bin COPY 至 HOME
cd ~
sudo cp jdk-6u38-linux-x64.bin /opt
cd /opt
sudo chmod a+x jdk-6u38-linux-x64.bin
sudo ./jdk-6u38-linux-x64.bin
sudo gedit ~/.bashrc &
至最後一行加上
export PATH=/opt/jdk1.6.0_38/bin:/opt/jdk1.6.0_38/lib:/opt/jdk1.6.0_38:$PATH
~/.bashrc