Creating .appxbundle using msbuild for (x86|x64|ARM)

霸气de小男生 提交于 2019-12-13 01:42:55

问题


i am trying to create .appxbundle using msbuild from developer command prompt i am using below command to create the same

MSBuild KitabooBookshelf.sln /p:Configuration=Release;OutDir=..\Release\;AppxBundle=Always;AppxBundlePlatforms="x86|x64|ARM"

but getting below processor architecture error. I did not find much useful resource related to this issue though many have faced similar issue. I am new to Windows store Application. trying to figure what i am doing wrong & how can i create .appxbundle using msbuild

"E:\Kitaboo Windows 8.1 2nd June 2015\KitabooBookShelf\KitabooBookshelf.csproj" (default target) (1) ->

"E:\Kitaboo Windows 8.1 2nd June 2015\DatabaseLibrary\DatabaseLibrary.csproj" ( default target) (3) ->

(ResolveSDKReferences target) -> C:\Program Files (x86)\MSBuild\12.0\bin\Microsoft.Common.CurrentVersion.targe ts(1803,5): error MSB3779: The processor architecture of the project being buil t "Any CPU" is not supported by the referenced SDK "Microsoft.VCLibs, Version=1 2.0". Please consider changing the targeted processor architecture of your proj ect (in Visual Studio this can be done through the Configuration Manager) to on e of the architectures supported by the SDK: "x86, x64, ARM". [E:\Kitaboo Windo ws 8.1 2nd June 2015\DatabaseLibrary\DatabaseLibrary.csproj]

C:\Program Files (x86)\MSBuild\12.0\bin\Microsoft.Common.CurrentVersion.targe ts(1803,5): error MSB3779: The processor architecture of the project being buil t "Any CPU" is not supported by the referenced SDK "SQLite.WinRT81, Version=3.9 .2". Please consider changing the targeted processor architecture of your proje ct (in Visual Studio this can be done through the Configuration Manager) to one of the architectures supported by the SDK: "x86, x64, ARM".

[E:\Kitaboo Window s 8.1 2nd June 2015\DatabaseLibrary\DatabaseLibrary.csproj]


回答1:


I am finally spending few hours able to solve this issue

Below is the command to create x86, ARM ,x64 bundle but it creates three .Appx file each for three different architecture. msbuild does not create single bundle .appxbundle

E:\Project Dir>MSBuild Project.sln /p:Configuration=Release;OutDir=..\Release\;AppxBundle=Always;AppxBundlePlatforms="x86|x64|ARM

Architecture error which i had above due to "Any CPU" i removed all "Any CPU" instance from .csproj and .sln file & replaced them with x86. and run above command i was able to creae .appx bundle for x86, ARM, x64. before running above msbuild command do not forget to remove Bin & obj folders from project which you will find after clicking show all button on main project.

I hope this helps to someone having similar issue.

Thanks



来源:https://stackoverflow.com/questions/35309142/creating-appxbundle-using-msbuild-for-x86x64arm

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!