add makefile rules for java