Fixed java binding build issues introduced in 38f3cc26.