Fix #1715 windows build fails when path contains spaces