Error building project on Windows platform

Hello Folks,

I am new to ionic and just went through the sample I saw on your getting started age.

I targeted the Windows platform but getting the following error while attempting to build/run the project:

c:\dev\mobile\wp\helloWP>ionic build windows

Running command: “C:\Program Files\nodejs\node.exe” c:\dev\mobile\wp\helloWP\hoo
ks\after_prepare\010_add_platform_class.js c:\dev\mobile\wp\helloWP
add to body class: platform-windows
Running command: cmd "/s /c “c:\dev\mobile\wp\helloWP\platforms\windows\cordova
build.bat”"
MSBuildToolsPath: C:\Program Files (x86)\MSBuild\14.0\bin\amd64
Building project: c:\dev\mobile\wp\helloWP\platforms\windows\CordovaApp.Windows.
jsproj
Configuration : debug
Platform : anycpu
C:\Program Files (x86)\MSBuild\Microsoft\VisualStudio\v14.0\AppxPackage\Microsof
t.AppXPackage.Targets(2176,5): error MSB6006: “MakeAppx.exe” exited with code 1.
[c:\dev\mobile\wp\helloWP\platforms\windows\CordovaApp.Windows.jsproj]
ERROR: Error code 1 for command: C:\Program Files (x86)\MSBuild\14.0\bin\amd64\m
sbuild with args: c:\dev\mobile\wp\helloWP\platforms\windows\CordovaApp.Windows.
jsproj,/clp:NoSummary;NoItemAndPropertyList;Verbosity=minimal,/nologo,/p:Configu
ration=debug,/p:Platform=anycpu
ERROR building one of the platforms: Error: cmd: Command failed with exit code 2

You may not have the required environment or OS to build this project
Error: cmd: Command failed with exit code 2
at ChildProcess.whenDone (C:\Users\aakeem\AppData\Roaming\npm\node_modules\c
ordova\node_modules\cordova-lib\src\cordova\superspawn.js:139:23)
at ChildProcess.emit (events.js:110:17)
at maybeClose (child_process.js:1015:16)
at Process.ChildProcess._handle.onexit (child_process.js:1087:5)

c:\dev\mobile\wp\helloWP>ionic run windows
Running command: “C:\Program Files\nodejs\node.exe” c:\dev\mobile\wp\helloWP\hoo
ks\after_prepare\010_add_platform_class.js c:\dev\mobile\wp\helloWP
add to body class: platform-windows
Running command: cmd "/s /c “c:\dev\mobile\wp\helloWP\platforms\windows\cordova
run.bat”"
MSBuildToolsPath: C:\Program Files (x86)\MSBuild\14.0\bin\amd64
Building project: c:\dev\mobile\wp\helloWP\platforms\windows\CordovaApp.Windows.
jsproj
Configuration : debug
Platform : anycpu
C:\Program Files (x86)\MSBuild\Microsoft\VisualStudio\v14.0\AppxPackage\Microsof
t.AppXPackage.Targets(2176,5): error MSB6006: “MakeAppx.exe” exited with code 1.
[c:\dev\mobile\wp\helloWP\platforms\windows\CordovaApp.Windows.jsproj]
ERROR: Error code 1 for command: C:\Program Files (x86)\MSBuild\14.0\bin\amd64\m
sbuild with args: c:\dev\mobile\wp\helloWP\platforms\windows\CordovaApp.Windows.
jsproj,/clp:NoSummary;NoItemAndPropertyList;Verbosity=minimal,/nologo,/p:Configu
ration=debug,/p:Platform=anycpu
ERROR running one or more of the platforms: Error: cmd: Command failed with exit
code 2
You may not have the required environment or OS to run this project

Please help

What version of Windows are you using? You do need the SDK: https://dev.windows.com/en-us/downloads/windows-10-sdk

Thanks,

I’m using Windows 8.

Checking the link you shared.

I have the same problem, you manage your fix?

I’m yet to get this fix.

I have downloaded & installed the SDK, same still.

This is what it get:

ERROR: Error code 1 for command: C:\Program Files (x86)\MSBuild\14.0\bin\amd64\m
sbuild with args: c:\dev\mobile\wp\ionic\hello\platforms\windows\CordovaApp.Wind
ows.jsproj,/clp:NoSummary;NoItemAndPropertyList;Verbosity=minimal,/nologo,/p:Con
figuration=debug,/p:Platform=anycpu
ERROR building one of the platforms: Error: cmd: Command failed with exit code 2

You may not have the required environment or OS to build this project
Error: cmd: Command failed with exit code 2

I got this error:
Error The following component requires .NET Native compilation which is not available when targeting ‘Windows10’ and ‘AnyCPU’. Consider changing the targeted processor architecture to one of the following: ‘x86, x64, ARM’ (if you are using command line this could be done by adding ‘–archs’ parameter, for example: ‘cordova build windows --archs=x64’). C:\Users\endriazizi\Desktop\VIRGINAPP\virginrevolutionapp\platforms\windows\plugins\pushwoosh-cordova-plugin\PushSDK.winmd 90