Closed davkean closed 8 years ago
This might be because VsInstallRoot isn't set? Can't figure out how this calculated.
VSInstallRoot looks like it respects VSINSTALLDIR if VisualStudioVersion is also set: https://github.com/Microsoft/msbuild/blob/60c73c914c01c62f5496c6d04683f77e967bbc68/src/Shared/BuildEnvironmentHelper.cs#L166.
Tried this, still didn't work.
Oh, I looked at the log - turns out this is NuGet.exe running MSBuild:
Using "Exec" task from assembly "Microsoft.Build.Tasks.Core, Version=15.1.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a".
Task "Exec" (TaskId:3)
Task Parameter:Command="C:\roslyn-project-system\build\..\build\bin\NuGet.exe" restore -verbosity quiet "C:\roslyn-project-system\build\..\src\ProjectSystem.sln" (TaskId:3)
"C:\roslyn-project-system\build\..\build\bin\NuGet.exe" restore -verbosity quiet "C:\roslyn-project-system\build\..\src\ProjectSystem.sln" (TaskId:3)
18:34:52.092 1>C:\roslyn-project-system\build\Targets\VSL.Imports.targets(365,3): error MSB4019: The imported project "C:\Program Files (x86)\MSBuild\Microsoft\VisualStudio\v15.0\VSSDK\Microsoft.VsSDK.targets" was not found. Confirm that the path in the <Import> declaration is correct, and that the file exists on disk. [C:\roslyn-project-system\src\Microsoft.VisualStudio.ProjectSystem.CSharp.VS\Microsoft.VisualStudio.ProjectSystem.CSharp.VS.csproj] [C:\roslyn-project-system\build\build.proj]
18:34:52.190 1>C:\roslyn-project-system\build\Targets\VSL.Imports.targets(365,3): error MSB4019: The imported project "C:\Program Files (x86)\MSBuild\Microsoft\VisualStudio\v15.0\VSSDK\Microsoft.VsSDK.targets" was not found. Confirm that the path in the <Import> declaration is correct, and that the file exists on disk. [C:\roslyn-project-system\src\Microsoft.VisualStudio.ProjectSystem.VisualBasic.VS\Microsoft.VisualStudio.ProjectSystem.VisualBasic.VS.csproj] [C:\roslyn-project-system\build\build.proj]
18:34:52.304 1>C:\roslyn-project-system\build\Targets\VSL.Imports.targets(365,3): error MSB4019: The imported project "C:\Program Files (x86)\MSBuild\Microsoft\VisualStudio\v15.0\VSSDK\Microsoft.VsSDK.targets" was not found. Confirm that the path in the <Import> declaration is correct, and that the file exists on disk. [C:\roslyn-project-system\src\Microsoft.VisualStudio.ProjectSystem.CSharp.VS\Microsoft.VisualStudio.ProjectSystem.CSharp.VS.csproj] [C:\roslyn-project-system\build\build.proj]
18:34:52.322 1>C:\roslyn-project-system\build\Targets\VSL.Imports.targets(365,3): error MSB4019: The imported project "C:\Program Files (x86)\MSBuild\Microsoft\VisualStudio\v15.0\VSSDK\Microsoft.VsSDK.targets" was not found. Confirm that the path in the <Import> declaration is correct, and that the file exists on disk. [C:\roslyn-project-system\src\Microsoft.VisualStudio.ProjectSystem.CSharp.VS\Microsoft.VisualStudio.ProjectSystem.CSharp.VS.csproj] [C:\roslyn-project-system\build\build.proj]
18:34:52.438 1>C:\roslyn-project-system\build\Targets\VSL.Imports.targets(365,3): error MSB4019: The imported project "C:\Program Files (x86)\MSBuild\Microsoft\VisualStudio\v15.0\VSSDK\Microsoft.VsSDK.targets" was not found. Confirm that the path in the <Import> declaration is correct, and that the file exists on disk. [C:\roslyn-project-system\src\Microsoft.VisualStudio.ProjectSystem.VisualBasic.VS\Microsoft.VisualStudio.ProjectSystem.VisualBasic.VS.csproj] [C:\roslyn-project-system\build\build.proj]
18:34:52.458 1>C:\roslyn-project-system\build\Targets\VSL.Imports.targets(365,3): error MSB4019: The imported project "C:\Program Files (x86)\MSBuild\Microsoft\VisualStudio\v15.0\VSSDK\Microsoft.VsSDK.targets" was not found. Confirm that the path in the <Import> declaration is correct, and that the file exists on disk. [C:\roslyn-project-system\src\Microsoft.VisualStudio.ProjectSystem.VisualBasic.VS\Microsoft.VisualStudio.ProjectSystem.VisualBasic.VS.csproj] [C:\roslyn-project-system\build\build.proj]
18:34:52.472 1>C:\roslyn-project-system\build\Targets\VSL.Imports.targets(365,3): error MSB4019: The imported project "C:\Program Files (x86)\MSBuild\Microsoft\VisualStudio\v15.0\VSSDK\Microsoft.VsSDK.targets" was not found. Confirm that the path in the <Import> declaration is correct, and that the file exists on disk. [C:\roslyn-project-system\src\ProjectSystemSetup\ProjectSystemSetup.csproj] [C:\roslyn-project-system\build\build.proj]
18:34:52.480 1>C:\roslyn-project-system\build\Targets\VSL.Imports.targets(365,3): error MSB4019: The imported project "C:\Program Files (x86)\MSBuild\Microsoft\VisualStudio\v15.0\VSSDK\Microsoft.VsSDK.targets" was not found. Confirm that the path in the <Import> declaration is correct, and that the file exists on disk. [C:\roslyn-project-system\src\VisualStudioEditorsSetup\VisualStudioEditorsSetup.csproj] [C:\roslyn-project-system\build\build.proj]
18:34:52.631 1>C:\roslyn-project-system\build\Targets\VSL.Imports.targets(365,3): error MSB4019: The imported project "C:\Program Files (x86)\MSBuild\Microsoft\VisualStudio\v15.0\VSSDK\Microsoft.VsSDK.targets" was not found. Confirm that the path in the <Import> declaration is correct, and that the file exists on disk. [C:\roslyn-project-system\src\ProjectSystemDogfoodSetup\ProjectSystemDogfoodSetup.csproj] [C:\roslyn-project-system\build\build.proj]
(TaskId:3)
18:34:52.674 1>C:\roslyn-project-system\build\build.proj(30,5): error MSB3073: The command ""C:\roslyn-project-system\build\..\build\bin\NuGet.exe" restore -verbosity quiet "C:\roslyn-project-system\build\..\src\ProjectSystem.sln"" exited with code 1.
Done executing task "Exec" -- FAILED. (TaskId:3)
18:34:52.674 1>Done building target "RestorePackages" in project "build.proj" -- FAILED.: (TargetId:2)
18:34:52.675 1>Done Building Project "C:\roslyn-project-system\build\build.proj" (Build target(s)) -- FAILED.
Filed this against NuGet: https://github.com/NuGet/Home/issues/3387.
Running from a Willow command-prompt, with the following variations of imports:
and
Under a Willow command-prompt, I would expect all of these to get found under C:\Program Files (x86)\Microsoft Visual Studio 15.0\MSBuild\Microsoft\VisualStudio\v15.0\VSSDK.
Instead I get: