Wednesday, February 13, 2008

Ubuntu + Eclipse: Round 2

Ok... so apparently, I was having all sorts of problems with my first installation of Eclipse 3.3. I was getting a whole crap load of exceptions in the logs. Also, every so often, my Eclipse would freeze, then shut down on me without notice, sometimes bringing down Ubuntu as well. Not to mention it didn't save any unsaved data (ARGH!!!).

So... I scrapped it! I removed Eclipse from my system... which took FOREVER. I did:

>sudo apt-get remove --purge eclipse
>sudo apt-get autoremove
>sudo apt-get autoclean

Then I went into /usr/lib and /usr/share to make sure the eclipse folder was gone. I then removed my workspace .eclipse folder. After this, I went into Synaptic package manager and completely removed all Eclipse packages and Sun Java 6 packages. And by all, I mean EVERYTHING!

I then reinstalled Eclipse and Sun Java 6 about 5 or 6 times using Synaptic, with no luck. Eclipse 3.2 wouldn't even start up. It kept complaining about a BundleException. No idea what that was. I finally gave up with Synaptic and went back to apt-get.

>sudo apt-get update
>sudo apt-get dist-upgrade
>sudo apt-get eclipse
>sudo apt-get sun-java6-jdk

Then I added /usr/lib/jvm/java-6-sun to the beginning of the lists in:

>sudo -b gedit /etc/jvm
>sudo -b gedit /etc/eclipse/java_home

I then ran eclipse using the following:

>eclipse -clean

which gave me an error:

searching for compatible vm...
testing /usr/lib/jvm/java-6-sun...found
Could not create /usr/local/lib/eclipse/.eclipseextension. Please run as root:
touch /usr/local/lib/eclipse/.eclipseextension
chmod 2775 /usr/local/lib/eclipse/.eclipseextension
chown root:staff /usr/local/lib/eclipse/.eclipseextension

So I did:

>sudo touch /usr/local/lib/eclipse/.eclipseextension
>sudo chmod 2775 /usr/local/lib/eclipse/.eclipseextension
>sudo chown root:staff /usr/local/lib/eclipse/.eclipseextension

Then ran again:

>eclipse -clean

This time, Eclipse 3.2 started up with no exceptions in the logs! YAY!

Not done yet... will try to install Aptana + RadRails + SubClipse now... wish me luck!

UPDATE:
After installing Aptana, everything seems to be running fine. Eclipse did not shut down on me... so I continued to install RadRails.

After installing RadRails, I checked the logs, and I got several exceptions. As I continued to use Eclipse, I continued to get a whole load of errors. However, Everything continued to work fine. I'm not sure what the error messages are, but they weren't bothering me, so I decided not to bother them!

Next came SubClipse. This installed without problems as well! And now I'm happily coding away again! Yay! Nightmare over! ...for now...


W

No comments: