fix several minor issues found during installing and building