tidy up and add a toplevel makefile to drive everything
formatting