fix typos and makefile issues