Windows installation fixes, smallr efactoring