fixed a few build errors