added basic makefile
added better errors
added framework
refactoring