fixed makefiles to work with BGQ