Skip to main content

Posts

Showing posts from 2011

Spring Roo: Missing com.sun:tools:jar:1.4.2

While trying to run a roo project with maven command I got an error saying "Missing  com . sun : tools : jar : 1.4 . 2" When I investigated the reason i found that it due to Java version(i.e 1.6) and Linux 64 bit. Then I installed Sun Java 5 on my system and changed default jdk.  After this when I run the maven to run the program I got the following error Exception in thread "main" java.lang.NoClassDefFoundError: javax/tools/JavaFileManager I felt that may be due to  https://jira.springsource.org/browse/ROO-224 So I again changed my JDK to Sun JDK 6 aand run the program.No the program magically started running.

Installing Sun JDK 5 on Ubuntu 11.10

Many times we would require to have older versions of java.Here are the steps install java 5 on Ubuntu 11.10 Run the following commands in a terminal $ sudo add-apt-repository "deb http://us.archive.ubuntu.com/ubuntu/ hardy multiverse" $ sudo add-apt-repository "deb http://us.archive.ubuntu.com/ubuntu/ hardy-updates multiverse" $ sudo apt-get update $ sudo apt-get install sun-java5-jdk To confirm if successfully installed run. $ sudo update-java-alternatives -l To switch the Java version, run. $ sudo update-java-alternatives -s java-1.5.0-sun Then confirm if switched successfully, run. $ java -version