fixing many build errors