Added makefile and updated main.cc for supporting older compilers.
Updated makefile.