Fixed bugs in the Makefile