Closed StingyJack closed 7 years ago
Look at the toolbar, set that to x64 or x86, if it isn't there. Add it
Thats a solution configuration - not the bitness (x86 or x64) of the assembly. Assemblies care about bitness, else you get an Image Format exception.
You have to make changes on the solution level. Or just implement the code required for AnyCpu support.
If you don't like it submit a PR.
Thats a solution configuration - not the bitness (x86 or x64) of the assembly. Assemblies care about bitness, else you get an Image Format exception.
I am well aware, but as you've set the platform target to x64 you need to set it solution wide as well (as @amaitland said). NuGet will take care of the rest.
Also, in the screenshot your full name is visible, you may or may not want to change that.
@merceyz thanks for the ident heads up. I've changed it to my birth name to avoid any confusion. =P
I guess I just don't follow the series of events that leads to this. One of the solutions I manage at work has about 200 projects, and a few of the projects need to reference Sap and Oracle issued assemblies. I only had to make the referencing project chain x64, not all the projects in the solution, and didnt have to change the solution platform (and with it about 180 projects - we did eventually do this).
I'm not trying to grief any you, and I don't really want AnyCPU (or even the project I was looking at that referenced this one). The inspection in msbuild simply didn't align with the error message I was seeing, and after reading the FAQ and the issues and through the cef# code it looked like a simple misunderstanding of solution platform vs assembly platform, but maybe its more complex than that and you don't feel like explaining. That's up to you, but I don't think you mean for the below to be able to happen.
$p$g>corflags slackui.exe
Microsoft (R) .NET Framework CorFlags Conversion Tool. Version 4.6.1055.0
Copyright (c) Microsoft Corporation. All rights reserved.
Version : v4.0.30319
CLR Header: 2.5
PE : PE32
CorFlags : 0x3
ILONLY : 1
**32BITREQ : 1**
32BITPREF : 0
Signed : 0
$p$g>corflags CefSharp.dll
Microsoft (R) .NET Framework CorFlags Conversion Tool. Version 4.6.1055.0
Copyright (c) Microsoft Corporation. All rights reserved.
Version : v4.0.30319
CLR Header: 2.5
PE : PE32+
CorFlags : 0x9
ILONLY : 1
**32BITREQ : 0**
32BITPREF : 0
Signed : 1
$p$g>corflags CefSharp.Core.dll
Microsoft (R) .NET Framework CorFlags Conversion Tool. Version 4.6.1055.0
Copyright (c) Microsoft Corporation. All rights reserved.
Version : v4.0.30319
CLR Header: 2.5
PE : PE32+
CorFlags : 0x18
ILONLY : 0
**32BITREQ : 0**
32BITPREF : 0
Signed : 1
The message your seeing is generated by an msbuild targets file see https://github.com/cefsharp/CefSharp/blob/master/NuGet/CefSharp.Common.targets#L3
The Platform property is currently used, if you are familiar with msbuild then by all means improve the checks and submit a PR :+1:
... and its telling me i still have the assembly set to AnyCPU. This may just be a simple misunderstanding on my part, but I read through the whole faq and a few threads and it looks like your warning is on the solution configuration platform name and not the actual assembly platform target (which can be different). I think the assembly bitness is what you want to be targeting, no?
What architecture x86 or x64? x64
On what operating system? Windows ME - (j/k Win 10)
Are you using
WinForms
,WPF
orOffScreen
? Dunno, wanted to see what this slack ui project was and cant compile itWhat steps will reproduce the problem? Assembly set to compile as x64, references cefsharp nuget packages. Build Project, Get Error
What is the expected output? What do you see instead? I expect to compile once I fix the assembly target platform.
Please provide any additional information below. screenshot has what I think is relevant. LMK if you need something else.
Does this problem also occur in the
CEF
Sample Application from http://opensource.spotify.com/cefbuilds/index.html (http://cefbuilds.com for older version)?Dunno. Not really important.