This project is read-only.

Building a WindowsPhone app for ARM, appx is invalid

Dec 9, 2014 at 9:01 PM
I've been trying to debug why when I use cmake with a generator "Visual Studio 2013 ARM" and msbuild with /p:Platform=ARM, I end up with an appx that won't deploy from the command line to a device.

If I open the generated solution in VS2013 and deploy from there it will work (since now I know it doesn't run MDILXapCompile to pre-compile binary assets for ARM)

After a lot of playing with makeappx, mdilxapcompile and dumpbin, it looks like the main app's winmd file is being generated with an x86 arch rather than ARM. Unhelpfully, AppDeployCmd just says optimization failed because an assembly was invalid. I had to use MDILXapCompile verbose on the generated appx to get more details. It pointed to the main winmd of my project. Here's what dumpbin gave me when I took a look at that files' headers:
C:\my_project>"C:\Program Files (x86)\Microsoft Visual Studio 12.0\VC\bin\dumpbin.exe" /headers C:\my_project\build\windows\WindowsPhone.ARM\Debug\my_project.winmd | find "machine"
             14C machine (x86)
                   32 bit word machine
Am I missing something? is this a bug?