question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

[MAUI] warning MSB3270: There was a mismatch between the processor architecture of the project being built...

See original GitHub issue

Platform

  • OS: iOS
  • MAUI: latest

Describe the bug When adding the Sharpnado.Tabs.Maui nuget to a simple class library targeting net6.0-ios, I get the following warning when building the library:

warning MSB3270: There was a mismatch between the processor architecture of the project being built "MSIL" and the processor architecture of the reference "C:\Nuget\sharpnado.tabs.maui\3.0.0\lib\net6.0-ios15.4\Maui.Tabs.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.

Could you please help me understand it and fix it ?

To Reproduce Steps to reproduce the behavior:

  1. Create a class library for net6.0
  2. Target net6.0-ios (see csproj below)
  3. Add a package reference to Sharpnado.Tabs.Maui (3.0.0)
  4. Build library
  5. See warning

csproj:

<Project Sdk="Microsoft.NET.Sdk">
  <PropertyGroup>
    <TargetFrameworks>net6.0-android;net6.0-ios</TargetFrameworks>
  </PropertyGroup>
  <ItemGroup>
    <PackageReference Include="Sharpnado.Tabs.Maui" Version="3.0.0" />
  </ItemGroup>
</Project>

Issue Analytics

  • State:closed
  • Created 10 months ago
  • Comments:9 (4 by maintainers)

github_iconTop GitHub Comments

1reaction
roubachofcommented, Dec 15, 2022

I have to figure out how the compatibility with the framework versions works… If someone could enlighten me:

I thought a .net6 lib could be use in a .net7 project, but it seems the other way around according to: .NET 7 breaking change: Library support for older frameworks - .NET

.NET 7 core libraries packages are supported for use in projects targeting .NET Framework 4.6.2 and later, .NET 6 and later, or .NET Standard 2.0 or later.

So could someone confirm I just have to always upgrade my libs to the latest .net version to be compatible with the larger number of projects ?

0reactions
roubachofcommented, Jan 3, 2023

were an issue in the csproj.user file (wtf). Version 3.0.1 fixes the issue

Read more comments on GitHub >

github_iconTop Results From Across the Web

There was a mismatch between the processor architecture ...
The message says that you are trying to use a dependency that is of an architecture that doesn't match the target architecture your...
Read more >
How do I fix the Visual Studio compile error, "mismatch ...
Go to the Build|Configuration Manager menu item. Find your project in the list, under Platform it will say "Any CPU"; Select the "Any...
Read more >
MSB3270: There was a mismatch between the processor ...
The warning was warning MSB3270: There was a mismatch between the processor architecture of the project being built "MSIL" and the processor ...
Read more >
Solved: Build warning - mismatch between the processor ...
Solved: warning MSB3270: There was a mismatch between the processor architecture of the project being built "MSIL" and the processor.
Read more >
SDK 7 does not generate MSB3270 "mismatch between ...
There's a possible regression in SDK 7 with regard to generating MSB3270 warning (mismatch between the processor architecture of the project ...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found