Skip to content

platform bitness mismatch with self-contained publish RID will compile/publish but will fail to run #698

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
TheRealPiotrP opened this issue Jan 20, 2017 · 2 comments
Assignees
Milestone

Comments

@TheRealPiotrP
Copy link
Contributor

Moved from https://github.com/dotnet/cli/issues/2922 on behalf of @guardrex


@blackdwarf Yes, it's still there with MSBuild. The setup is like this ...

<PropertyGroup>
  <TargetFramework>netcoreapp1.2</TargetFramework>
  <OutputType>Exe</OutputType>
  <RuntimeIdentifiers>win10-x64</RuntimeIdentifiers>
  <PlatformTarget>x86</PlatformTarget>
</PropertyGroup>

It will compile without any indication of a problem using dotnet publish -r win10-x64 ...

capture
When you try to run the app, it 💥 with ...

Unhandled Exception: System.BadImageFormatException: Could not load file or assembly 
'testselfcontained.dll'. An attempt was made to load a program with an incorrect format.
@srivatsn srivatsn added the Bug label Jan 27, 2017
@srivatsn srivatsn added this to the 1.0 RTM milestone Jan 27, 2017
@nguerrera
Copy link
Contributor

Closing as duplicate of #396, the plan for which will fix this.

@nguerrera nguerrera reopened this Feb 3, 2017
@nguerrera
Copy link
Contributor

This is not covered by #396.

@nguerrera nguerrera modified the milestones: 1.1, 1.0 RTM Feb 3, 2017
@dsplaisted dsplaisted modified the milestones: 2.0, 1.1 May 15, 2017
@livarcocc livarcocc assigned livarcocc and unassigned nguerrera Jul 20, 2017
mmitche pushed a commit to mmitche/sdk that referenced this issue Jun 5, 2020
…607.62 (dotnet#698)

- Microsoft.DotNet.Arcade.Sdk - 1.0.0-beta.19307.62
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

5 participants