runtime: error MSB4044: The "CopyRefAssembly" task was not given a value for the required parameter "SourcePath"

Description

I’m trying to get Windows Forms master to work with VS 16.8, I bumped the tools and the SDK versions from 5.0.100-preview.6.20310.4 to 5.0.100-rc.1.20454.5 (inspired by https://github.com/dotnet/runtime/pull/41947):

Commit: https://github.com/dotnet/winforms/commit/4a5a4e9fc08f6021a784d5f054d5cd5dbff4fa18

diff --git a/global.json b/global.json
index 9823cc1dc..e2ed3ec0b 100644
--- a/global.json
+++ b/global.json
@@ -1,6 +1,6 @@
 {
   "tools": {
-    "dotnet": "5.0.100-preview.8.20417.9",
+    "dotnet": "5.0.100-rc.1.20454.5",
     "runtimes": {
       "dotnet/x64": [
         "$(MicrosoftNETCoreAppPackageVersion)"
@@ -11,7 +11,7 @@
     }
   },
   "sdk": {
-    "version": "5.0.100-preview.8.20417.9"
+    "version": "5.0.100-rc.1.20454.5"
   },
   "msbuild-sdks": {
     "Microsoft.DotNet.Arcade.Sdk": "5.0.0-beta.20459.8",

and the build fails:

Build FAILED.

C:\Development\winforms\.dotnet\sdk\5.0.100-rc.1.20454.5\Microsoft.Common.CurrentVersion.targets(4244,5): error MSB4044: The "CopyRefAssembly" task was not given a value for the required parameter "SourcePath". [C:\Development\winforms\pkg\Microsoft.Dotnet.WinForms.ProjectTemplates\Microsoft.Dotnet.Winforms.ProjectTemplates.csproj]
C:\Development\winforms\.dotnet\sdk\5.0.100-rc.1.20454.5\Microsoft.Common.CurrentVersion.targets(4244,5): error : Expected file "C:\Development\winforms\artifacts\obj\Accessibility\Debug\netcoreapp5.0\ref\Accessibility.dll" does not exist. [C:\Development\winforms\src\Accessibility\src\Accessibility.ilproj]
    0 Warning(s)
    2 Error(s)

About this issue

  • Original URL
  • State: closed
  • Created 4 years ago
  • Comments: 18 (16 by maintainers)

Most upvoted comments

Looks like I’m unblocked now, thank you @wli3!