Fix intermediate and output directories for msbuild