Fixed the makefile and manhattan distance