updated build related stuff, and some other random fixes