Fix errors in MSBuild prperties initialization in System.Private.CoreLib.csproj (#12356)
Fixes issue #12355
Project System.Private.CoreLib.csproj imports directly Microsoft.Net.Compilers.props
at line# 4 before including dir.props from repo root. $(RepoRoot)/dir.props imports
Microsoft.Net.Compilers.props at line# 186. As a result of this sequence of duplicated
project imports and lack of safeguards against importing the same .props file twice
MSBuild reports that Microsoft.Net.Compilers.props file is included twice with warning
that second import will be ignored - in this case not evaluated. This results
in initialization of Microsoft.Net.Compilers.props values to defaults because MSBuild
evaluates Microsoft.Net.Compilers.props only once before $(RepoRoot)/dir.props are included.
Removing import of Microsoft.Net.Compilers.props from System.Private.CoreLib.csproj
and moving $(RepoRoot)/dir.props file import to top of System.Private.CoreLib.csproj
solves these problems by ensuring expected order of evaluation of Microsoft.Net.Compilers.props
file by MSBuild after all project wide values are initialized in $(RepoRoot)/dir.props.