some build fixes for fresh environment.