updated makefile for generator and added -O3 option