small code changes, Makefile fix