After finding out all I was able to build out were x86 bits I spend last night fixing my game to also run under ARM & x64. What you need are the jpeglib, libxml2, libpng, and zlib static libraries for ARM and/or x64 but since they are not included in the Cocos2d-x Metro solution you can follow the steps below.
1) download the static release libs I created from here: https://github.com/trentmillar/cocos2d-x-metro-static-libs
2) Using the simple game pathing as an example create an ARM & x64 folder under:
C:2dxWin8\cocos2dx\platform\third_party\win8_metro\libraries and copy the 4 libs under each folder.
3) Create both the x64 & ARM configurations in Visual Studio, this explains it better than I could http://www.viva64.com/en/l/0004/ follow steps 1 to 4. Make sure you choose to copy existing settings from the x86 configuration.
4) Add the library folder to the new configurations.
- open the property window for your game project in Visual Studio
- go to “Configuration Properties”~~>“VC++ Directories”~~>“Library Directories”
- add \$cocos2dx\platform\third_party\win8_metro\libraries\ARM; Note, change ARM to x64 for the x64 configuration
- add libpng.lib, libxml2.lib, jpeglib.lib, and zlib.lib to the “Linker”~~>“Input”~~>“Additional Dependencies” so they link into the build.
Other possible gotchas-
- You will probably have issues compiling the hlsl shaders. When you create the new configurations it looks like the build types for these are lost. Make sure you right-click each shader under cocos2dx and change the Shader Type to either pixel or vertex (/ps /vs).
The pre-compiled header should not be compiled so make sure you change this in the project properties. This essentially removes the /Yu switch
Add the following to the Preprocessor Definitions in the project properties: _CRT_SECURE_NO_WARNINGS
That should be it.
Note, the jpeglib lib I built is probably not the correct version and is missing some methods CCImage was expecting. Since these methods are only called when on a WOPhone I simply removed them from the CCImage class file. I will probably look into this later but for now you need to be aware of this.
- I have not full tested the libs, if you find issues please reply to this post so I can fix and update.
- I do not have a WinRT ARM tablet to verify the arm libs. If you do can you reply back to let us all know if they worked?
- I was able to test my game using these libs on x86 and x64 successfully.