fix some compile time issues