The attached patch adds support for compiling with JDK 8.
Because current ant releases too lack support for JDK 8, one also needs to pass -Dbuild.compiler=modern property to ant for compile target to work.
PS. The JDK 8 early access releases can be downloaded from here: http://jdk8.java.net/download.html
-Mikko