fix build if jdk < 1.8