Mismatch between processor architecture.
See original GitHub issueSteps to reproduce
- In VS 2015 create a .net web project targeting full framework.
- Add a Nuget package reference to “Microsoft.ServiceFabric.Services” which targets only AMD64. or any other package that targets only AMD64.
- Build -> build will be fine.
- Open this project in another machine with VS 2017 and this will migrate the project.
- Build
Expected behavior
Build should succeed
Actual behavior
Build shows several warnings
1>------ Build started: Project: WebApplication1, Configuration: Debug Any CPU ------ 1>C:\Program Files (x86)\Microsoft Visual Studio\2017\Enterprise\MSBuild\15.0\Bin\Microsoft.Common.CurrentVersion.targets(1964,5): warning MSB3270: There was a mismatch between the processor architecture of the project being built “x86” and the processor architecture of the reference “C:\Users\ravipal.nuget\packages\microsoft.servicefabric.data\2.4.164\lib\net45\Microsoft.ServiceFabric.Data.dll”, “AMD64”. This mismatch may cause runtime failures. Please consider changing the targeted processor architecture of your project through the Configuration Manager so as to align the processor architectures between your project and references, or take a dependency on references with a processor architecture that matches the targeted processor architecture of your project. 1>C:\Program Files (x86)\Microsoft Visual Studio\2017\Enterprise\MSBuild\15.0\Bin\Microsoft.Common.CurrentVersion.targets(1964,5): warning MSB3270: There was a mismatch between the processor architecture of the project being built “x86” and the processor architecture of the reference “C:\Users\ravipal.nuget\packages\microsoft.servicefabric.data\2.4.164\lib\net45\Microsoft.ServiceFabric.Data.Interfaces.dll”, “AMD64”. This mismatch may cause runtime failures. Please consider changing the targeted processor architecture of your project through the Configuration Manager so as to align the processor architectures between your project and references, or take a dependency on references with a processor architecture that matches the targeted processor architecture of your project. 1>C:\Program Files (x86)\Microsoft Visual Studio\2017\Enterprise\MSBuild\15.0\Bin\Microsoft.Common.CurrentVersion.targets(1964,5): warning MSB3270: There was a mismatch between the processor architecture of the project being built “x86” and the processor architecture of the reference “C:\Users\ravipal.nuget\packages\microsoft.servicefabric\5.4.164\lib\net45\Microsoft.ServiceFabric.Internal.dll”, “AMD64”. This mismatch may cause runtime failures. Please consider changing the targeted processor architecture of your project through the Configuration Manager so as to align the processor architectures between your project and references, or take a dependency on references with a processor architecture that matches the targeted processor architecture of your project. 1>C:\Program Files (x86)\Microsoft Visual Studio\2017\Enterprise\MSBuild\15.0\Bin\Microsoft.Common.CurrentVersion.targets(1964,5): warning MSB3270: There was a mismatch between the processor architecture of the project being built “x86” and the processor architecture of the reference “C:\Users\ravipal.nuget\packages\microsoft.servicefabric\5.4.164\lib\net45\Microsoft.ServiceFabric.Internal.Strings.dll”, “AMD64”. This mismatch may cause runtime failures. Please consider changing the targeted processor architecture of your project through the Configuration Manager so as to align the processor architectures between your project and references, or take a dependency on references with a processor architecture that matches the targeted processor architecture of your project. 1>C:\Program Files (x86)\Microsoft Visual Studio\2017\Enterprise\MSBuild\15.0\Bin\Microsoft.Common.CurrentVersion.targets(1964,5): warning MSB3270: There was a mismatch between the processor architecture of the project being built “x86” and the processor architecture of the reference “C:\Users\ravipal.nuget\packages\microsoft.servicefabric.services\2.4.164\lib\net45\Microsoft.ServiceFabric.Services.dll”, “AMD64”. This mismatch may cause runtime failures. Please consider changing the targeted processor architecture of your project through the Configuration Manager so as to align the processor architectures between your project and references, or take a dependency on references with a processor architecture that matches the targeted processor architecture of your project. 1>C:\Program Files (x86)\Microsoft Visual Studio\2017\Enterprise\MSBuild\15.0\Bin\Microsoft.Common.CurrentVersion.targets(1964,5): warning MSB3270: There was a mismatch between the processor architecture of the project being built “x86” and the processor architecture of the reference “C:\Users\ravipal.nuget\packages\microsoft.servicefabric.services\2.4.164\lib\net45\ServiceFabricServiceModel.dll”, “AMD64”. This mismatch may cause runtime failures. Please consider changing the targeted processor architecture of your project through the Configuration Manager so as to align the processor architectures between your project and references, or take a dependency on references with a processor architecture that matches the targeted processor architecture of your project. 1>C:\Program Files (x86)\Microsoft Visual Studio\2017\Enterprise\MSBuild\15.0\Bin\Microsoft.Common.CurrentVersion.targets(1964,5): warning MSB3270: There was a mismatch between the processor architecture of the project being built “x86” and the processor architecture of the reference “C:\Users\ravipal.nuget\packages\microsoft.servicefabric\5.4.164\lib\net45\System.Fabric.dll”, “AMD64”. This mismatch may cause runtime failures. Please consider changing the targeted processor architecture of your project through the Configuration Manager so as to align the processor architectures between your project and references, or take a dependency on references with a processor architecture that matches the targeted processor architecture of your project. 1>C:\Program Files (x86)\Microsoft Visual Studio\2017\Enterprise\MSBuild\15.0\Bin\Microsoft.Common.CurrentVersion.targets(1964,5): warning MSB3270: There was a mismatch between the processor architecture of the project being built “x86” and the processor architecture of the reference “C:\Users\ravipal.nuget\packages\microsoft.servicefabric\5.4.164\lib\net45\System.Fabric.Strings.dll”, “AMD64”. This mismatch may cause runtime failures. Please consider changing the targeted processor architecture of your project through the Configuration Manager so as to align the processor architectures between your project and references, or take a dependency on references with a processor architecture that matches the targeted processor architecture of your project. 1>WebApplication1 -> C:\Users\ravipal\Documents\Visual Studio 2017\Projects\WebApplication1\src\WebApplication1\bin\Debug\net452\WebApplication1.exe 1>Done building project “WebApplication1.csproj”. ========== Build: 1 succeeded or up-to-date, 0 failed, 0 skipped ==========
Environment data
dotnet --info
output:
.NET Command Line Tools (1.0.0-rc4-004847)
Product Information: Version: 1.0.0-rc4-004847 Commit SHA-1 hash: b7692237d1
Runtime Environment: OS Name: Windows OS Version: 10.0.14393 OS Platform: Windows RID: win10-x64 Base Path: C:\Program Files\dotnet\sdk\1.0.0-rc4-004847
Issue Analytics
- State:
- Created 7 years ago
- Reactions:4
- Comments:24 (7 by maintainers)
I’m able to reproduce this issue as well. I have tried with both
x64
andAny CPU
configurations in my solution.My
csproj
:Errors:
I’m having this issue with dotnetcore2.0 and vs2017 15.3.1