Expand cmd-line in * Linker * module by double-quoting arguments with spaces when needed.
Double double-quotes are correctly escaped as suggested by @ruiu.
Tested on Windows and WSL Ubuntu. The cmd-line in the S_ENVBLOCK can now be extracted and executed as-it on Windows; however on Linux that would require some extra parsing as single/double-quotes are treated differently.
This is a replacement for D46427. After discussing with @lantictac offline, we agreed that I will finish his patch.
============================================================ Mod 0001 | `* Linker *`: ... 64 | S_ENVBLOCK [size = 404] - cwd - /mnt/f/svn/buildWSL/tools/lld/test/COFF - exe - /mnt/f/svn/buildWSL/bin/lld-link - pdb - /mnt/f/svn/buildWSL/tools/lld/test/COFF/Output/pdb-linker-module.test.tmp.pdb - cmd - /debug /pdb:/mnt/f/svn/buildWSL/tools/lld/test/COFF/Output/pdb-linker-module.test.tmp.pdb /nodefaultlib "/entry:1 ""hello"" 2" "/manifestuac:level='asInvoker' uiAccess='false'" /mnt/f/svn/lld/test/COFF/Inputs/pdb-diff.obj /force