Don't compile java 6 class when not building with java 6 or later.