如 #pkgrm SUNWj3dmo SUNWj3man SUNWj3dev SUNWj3rt SUNWj3dvx SUNWj3rt ...... 开始安装新的java环境:uncompress jdk-6u21-solaris-sparc.tar.Z tar xvf jdk-6u21-solaris-sparc.tar 在自己创建的目录里解压!如在/usr/local/sparc_sun下
export JAVA_HOME=/usr/jdk/jdk1.6.0_21 export JRE_HOME=/usr/jdk/jdk1.6.0_21/jre export PATH=$JAVA_HOME/bin:$PATH export CLASSPATH=.:$JAVA_HOME/lib/dt.jar:$JAVA_HOME/lib/tools.jar 然后输入source /etc/profile 生效配置文件,最后在输入java -version显示: root@ASM2 # java -version java version "1.6.0_21" Java(TM) SE Runtime Environment (build 1.6.0_21-b06) Java HotSpot(TM) Server VM (build 17.0-b16, mixed mode)
2. gunzip gcc-3.4.6-sol8-sparc-local.gz 3. pkgadd –d gcc-3.4.6-sol8-sparc-local 4. 手工设置root环境变量,添加PATH 、LD_LIBRARY_PAT export PATH=$PATH: /usr/local/bin export LD_LIBRARY_PATH=$ LD_LIBRARY_PATH: /usr/local/lib
输入:gcc -c
root@ASM2 # gcc -v Reading specs from /usr/local/lib/gcc-lib/sparc-sun-solaris2.8/3.1/specs Configured with: ../configure --with-as=/usr/ccs/bin/as --with-ld=/usr/ccs/bin/l d --disable-nls Thread model: posix gcc version 3.1