问题
I'm using 1.0.0-beta7 x64 but visual studios insists I'm using x86. When I delete all my runtimes except the one I'm targeting I get this:
I can't find a reference to x86 anywhere in my project.
When I hover over the Solution DNX SDK version here it shows the x86 version but I don't know where it's getting this from. Currently this isn't causing any problems I'm just trying to understand what's going on.
回答1:
Right-click in your, web (not solution) project and select Properties. Click "Use Specific Runtime" and pick the dnx runtime that you want from the dropdown. All this does is set the "sdkVersion" in the /Properties/launchSettings.json of your project.
The "sdk" in your global.json indicates the minimum sdk version that the project will run but won't run your project against it. It'll take the setting you have in launchSettings.json instead.
回答2:
Are you running a 32bit Windows?
If not, I would then suggest you clean out your runtimes.
C:\Users\USERNAME\.dnx\runtimes
Then do a fresh install dnvm upgrade
or perhaps dnvm install <version>
. Whilst you are at it you might as well update your dnvm as well dnvm update-self
.
Then set your runtimes on the web project properties, and the global.json, to x64. If you are using IIS Express to debug, set to use 64 bit version of IIS Express.
I hope this helps!
来源:https://stackoverflow.com/questions/32988589/how-to-force-visual-studio-to-use-x64-dnx-sdk-architecture