Improve makefile rules