fix Makefile
refactoring