Define stand-in optional workloads targets (#6813)
Define stand-in optional workloads targets (#6813)

https://github.com/dotnet/project-system/pull/7432 added a design-time target called CollectSuggestedWorkloads to https://github.com/project-system/blob/main/src/Microsoft.VisualStudio.ProjectSystem.Managed/ProjectSystem/DesignTimeTargets/Microsoft.Managed.DesignTime.targets. Unfortunately, that change did not account for the fact that this design-time targets file is used by non-SDK projects or projects using earlier SDKs. Such projects now fail with the error: `The target "GetSuggestedWorkloads" does not exist in the project.`

https://github.com/dotnet/project-system/pull/7553 temporarily worked around this by conditioning CollectSuggestedWorkloads on SDK projects with MissingWorkloadPacks. This change moves the dummy target (CollectSuggestedWorkloads) to Microsoft.Common.targets. That would also avoid bugs like https://github.com/dotnet/project-system/issues/7561 in which a project that doesn't include the design-time targets fails because the CollectSuggestedWorkloads design-time target cannot be found.

However, defining a dummy CollectSuggestedWorkloads in Microsoft.Common.targets would break the workload functionality for SDK projects because the SDK workload targets https://github.com/dotnet/sdk/blob/release/6.0.1xx/src/Tasks/Microsoft.NET.Build.Tasks/targets/Microsoft.NET.Sdk.ImportWorkloads.targets are imported before Microsoft.Common.targets. The dummy target would therefore override the real target.

rainersigwald/msbuild,rainersigwald/msbuild,sean-gilliam/msbuild,AndyGerlicher/msbuild,AndyGerlicher/msbuild,AndyGerlicher/msbuild,AndyGerlicher/msbuild,sean-gilliam/msbuild,rainersigwald/msbuild,rainersigwald/msbuild,sean-gilliam/msbuild,sean-gilliam/msbuild