Wednesday, May 23, 2007

Sun Studio 11 in Debian

Yesterday when I tried to install sun studio 11 in my Debian Sid, I was a bit disappointed when I learned that they only provide the rpm packages for Sun Studio. Anyways, I was able to install that with the help of alien.

Here is a short how-to of doing that:

1. Download sun studio 11 from here.

2. Install some necessary packages:

$sudo apt-get install libmotif-dev sun-java5-jdk fakeroot alien

[Note: This version of sun studio does not run with sun-java6-jdk]

3. Go to the folder where you downloaded sun studio and execute these:

mkdir sun-studio
cd sun-studio/
tar xvjf ../studio11-lin-x86.tar.bz2
cd kits/ide/
mkdir packages_deb
cd ../packages
cp `ls -1 *.rpm | grep -v locale | grep -v motif | \
grep -v x86_64` ../packages_deb/

cd ../packages_deb/
fakeroot alien *
rm -f *.rpm
sudo dpkg -i --force-overwrite *.deb

[Note: If you are running a 64 bit OS then omit grep -v x86_64 part.]

4. The installation is complete now.

Both Sun Studio and NetBeans IDE are installed in /opt/sun by default.

Now you can run Netbeans IDE 3.5 by running this:

$/opt/sun/netbeans/3.5V11/bin/runide.sh -jdkhome /usr/lib/jvm/java-1.5.0-sun

And run Sun Studio 11 by executing this:

$/opt/sun/sunstudio11/bin/sunstudio --jdkhome /usr/lib/jvm/java-1.5.0-sun

[Note: The package comes bundled with j2sdk 1.4 (look inside kits folder), so you can also install that in place of sun-java5-sdk. When you alien that rpm be sure to use the '--scripts' switch.]

You can find more info here.

No comments:

Back to Blogging

After a failed attempt last year to get back to blogging, I'm trying it again this year. I really wanted to get back, but got busy will...