MSBuild Error MSB4096 with Azure SDK 2.9.1

So, here is the problem: I recently upgraded my development computer to Windows 10 (from 8.1), and then from Visual Studio Enterprise 2015 (since 2013). I also upgraded to Azure SDK 2.9.1 (from 2.4). I reloaded extensions and updates and was easily saddled up to create and run the solution locally.

However, this is a different story when it comes to publishing on Azure. I have a script to run the MSbuild command, which used to work like a charm. But now it ends with the following error:

"C: \ development \ Organization \ Development \ Project42.sln" (default target) (1) β†’ "C: \ development \ Organization \ Development \ Project42.Azure \ Project42.Azure.ccproj.metaproj" (default goal) (12) β†’ "C: \ development \ Organization \ Development \ Project42.Azure \ Project42.Azure.ccproj" (default target) (13) β†’ (Purpose PrepareRoleItems) β†’ C: \ Program Files (x86) \ MSBuild \ Microsoft \ VisualStudio \ v14.0 \ Windows Azure Tools \ 2.9 \ Microsoft.WindowsAzure.targets (1378.5): error MSB4096: item "C: \ development \ Organization \ Development \ Project42.Admin.Web \ Project42.Admin.Web. csproj "in the list of items" ProjectReferenceWithConfiguration "does not define a value for the metadata" Name ". To use this metadata, qualify it by specifying% (ProjectReferenceWithConfiguration.Name), or make sure that all items in this list define a value for this metadata. [C: \ development \ Organization \ Development \ Project42.Azure \ Project42.Azure.ccproj]

I assume that this problem comes from the update, and I can’t put my finger on it. Any suggestion for troubleshooting?

+2
source share
1 answer

OK, I have a solution, but for this I need to change the following configuration file:

C: \ Program Files (x86) \ MSBuild \ Microsoft \ VisualStudio \ v14.0 \ Windows Azure Tools \ 2.9 \ Microsoft.WindowsAzure.targets

To write

<ProjectName>%(ProjectReferenceWithConfiguration.Name)</ProjectName>

instead

<ProjectName>%(Name)</ProjectName>

in two places: ligne 1380 and 1395. He did the trick!

+1
source

Source: https://habr.com/ru/post/1265551/


All Articles