Makefile.template corrections (thanks Dhruv)