fixed dependencies and backward compatibility to java-7