fix outofmemory during build on windows