fix some build errors