On Tuesday 16 May 2006 10:05, "wu chuanwen" <[EMAIL PROTECTED]> wrote about 'Re: [gentoo-user] cause jdk1.5 emerge tomcat error!': > Now my problem is : > I have both jdk1.5 and 1.4 now. > $ java-config -L > [sun-jdk-1.4.2.10] "Sun JDK 1.4.2.10" > (/etc/env.d/java/20sun-jdk-1.4.2.10) [sun-jdk-1.5.0.06] "Sun JDK > 1.5.0.06" (/etc/env.d/java/20sun-jdk-1.5.0.06) * I compiled all the > dev-java packages by javac1.5.Now when i compile > commons-pool-1.2-r1,"enum" can't be recognized as a keyword.And when i > switch to jdk 1.4,the message is "UnsupportedClassVersionError". How can > i fix this problem now besides re-emerge all the packages in dev-java?
Find what package owns the class/jar that's giving a UnsupportedClassVersionError (you might find equery from gentoolkit suited to this task) and recompile it with javac 1.4. This /could/ end up "chaining" down (meaning, that package requires you to compile a different package with 1.4 and so on)to where you have to compile everything with JDK 1.4, but maybe not. As covered before, JDK 5 (1.5) is masked for a reason. You really shouldn't unmask it unless you are ready to deal with the problems *yourself*. Many on the list will be either unable or unwilling to help you, and I have severe limits in my knowledge, having never actually installed JDK 1.5 on Gentoo, only the Windows boxes I've been forced to use for various work-related tasks. -- "If there's one thing we've established over the years, it's that the vast majority of our users don't have the slightest clue what's best for them in terms of package stability." -- Gentoo Developer Ciaran McCreesh
pgphd4y7uorfq.pgp
Description: PGP signature