Why do I get errors when building a hybrid app - visual-studio-2013

When I'm trying to build and deploy a new hybrid app template (with no changes done) build fails and I receive this output:
1>------ Rebuild All started: Project: BlankCordovaApp2, Configuration: Debug Android ------
1>C:\Program Files (x86)\MSBuild\Microsoft\VisualStudio\v12.0\TypeScript\Microsoft.TypeScript.targets(95,5): warning : The TypeScript Compiler was given no files for compilation, so it will skip compiling.
1> GeneratedJavascript=
1> C:\Users\YA\documents\visual studio 2013\Projects\BlankCordovaApp2\BlankCordovaApp2>call "C:\Program Files (x86)\nodejs\"\nodevars.bat
1>C:\Program Files (x86)\MSBuild\Microsoft\VisualStudio\v12.0\CordovaTools\vs-mda-targets\Microsoft.MDA.targets(208,5): error : "MySQL" �� ���� ����७��� ��� ���譥�
1>C:\Program Files (x86)\MSBuild\Microsoft\VisualStudio\v12.0\CordovaTools\vs-mda-targets\Microsoft.MDA.targets(208,5): error : ��������, �ᯮ��塞�� �ணࠬ��� ��� ������ 䠩���.
1>C:\Program Files (x86)\MSBuild\Microsoft\VisualStudio\v12.0\CordovaTools\vs-mda-targets\Microsoft.MDA.targets(208,5): error : "MySQL" �� ���� ����७��� ��� ���譥�
1>C:\Program Files (x86)\MSBuild\Microsoft\VisualStudio\v12.0\CordovaTools\vs-mda-targets\Microsoft.MDA.targets(208,5): error : ��������, �ᯮ��塞�� �ணࠬ��� ��� ������ 䠩���.
1> Your environment has been set up for using Node.js 0.10.33 (ia32) and npm.
1> ------ Ensuring correct global installation of package from source package directory: C:\PROGRAM FILES (X86)\MICROSOFT VISUAL STUDIO 12.0\COMMON7\IDE\EXTENSIONS\SLSJAGN5.MZC\packages\vs-mda
========== Rebuild All: 0 succeeded, 1 failed, 0 skipped ==========
Maybe errors text is in Russian, but I can't figure out how to change encoding in Output Window. I'm using Russian Windows 7, but VS (2013 Community) was intentionally set up in English without any language pack. Never had any problems with Russian text in Output before on other PCs. Also, I've checked all environment variables mentioned in some other topics related to Cordova, they seems to be OK.
Any suggestions how to track and solve this?
EDIT: As initial system isn't available for now, I've tried it on my home system. I'm receiving another output but with the same result - build fails:
1>------ Rebuild All started: Project: BlankCordovaApp4, Configuration: Debug Android ------
1>C:\Program Files (x86)\MSBuild\Microsoft\VisualStudio\v12.0\TypeScript\Microsoft.TypeScript.targets(95,5): warning : The TypeScript Compiler was given no files for compilation, so it will skip compiling.
1> GeneratedJavascript=
1> d:\mydocuments\visual studio 2013\Projects\BlankCordovaApp4\BlankCordovaApp4>call "C:\Program Files (x86)\nodejs\"\nodevars.bat
1> Your environment has been set up for using Node.js 0.10.26 (ia32) and npm.
1> ------ Ensuring correct global installation of package from source package directory: C:\PROGRAM FILES (X86)\MICROSOFT VISUAL STUDIO 12.0\COMMON7\IDE\EXTENSIONS\0N5RFQMM.AHA\packages\vs-mda
========== Rebuild All: 0 succeeded, 1 failed, 0 skipped ==========
System is Windows 7 x64 HP. I've checked there was no failed dependency report. Still no result. I've tried to follow this Unable to build Cordova project in Visual Studio, but no luck also. And no errors in Error List window.
sighs
Suggestions, pleeease?

I've solved by removing doing what is said here: 'MySQL' is not recognized as an internal command (Apache Cordova for visual studio) and also removing C:\Users\Miquel\AppData\Roaming\npm\node_modules\vs-mda\node_modules\*.* and C:\Users\Miquel\AppData\Roaming\npm-cache\*.*
Then in cmd I went to C:\Users\Miquel\AppData\Roaming\npm\node_modules\vs-mda and ran:
npm install

Related

Compile user mode driver in Visual Studio 2013

There is a driver project https://github.com/Psypher9/VG-STC-Driver/tree/master/WinVgStc .
I want to compile it.
I have:
Windows 10 19041.1
Visual Studio 2013 Community 12.0.40629.0
From this page https://learn.microsoft.com/en-us/windows-hardware/drivers/download-the-wdk installed:
Refreshed Windows SDK 10.0.19041.16385 for Windows 10, version 2004
Refreshed WDK for Windows 10, version 2004
Issue:
Trying to build, get errors:
1>------ Build started: Project: WinVgStc, Configuration: Release x64 ------
1> Device.c
1>c:\users\usr\downloads\winvgstc\winvgstc\driver.h(18): fatal error C1083: Cannot open include file: 'wdf.h': No such file or directory
1> Driver.c
1>c:\users\usr\downloads\winvgstc\winvgstc\driver.h(18): fatal error C1083: Cannot open include file: 'wdf.h': No such file or directory
1> Queue.c
1>c:\users\usr\downloads\winvgstc\winvgstc\driver.h(18): fatal error C1083: Cannot open include file: 'wdf.h': No such file or directory
1> Generating Code...
========== Build: 0 succeeded, 1 failed, 0 up-to-date, 0 skipped ==========
When I downloaded this project from GitHub the first error was, that there is no usermode drivers toolset. In project properties I changed it to Visual Studio 2013 (v120). Then I got the error list above.
At this point I didn't have SDK and WDK I mentioned in the list above, so I downloaded it.
After restarting Visual Studio I still have errors. Also there is still only 2 variants of platform toolset in project properties: Visual Studio 2013 (v120) and Visual Studio 2013 - Windows XP (v120_xp).
What should I do to compile it on the current Visual Studio?

Project Blank App using Visual Studio Tools for Apache Cordova not build

I installed Visual Studio Tools environment for Apache Cordova, follow all MSDN guidelines correctly, however when I create a Blank App and give the build he insists on returning the error that I have attached a picture. I've tried some solutions I found on the internet yesterday and even uninstalled every environment and installed again, but the error persists. I suspect it is related to the wrong path when calling the nodevars.bat file but do not know where to set the correct path. Does anyone know what this is?
Output:
1>------ Build started: Project: BlankCordovaApp2, Configuration: Debug Android ------
1>C:\Program Files (x86)\MSBuild\Microsoft\VisualStudio\v12.0\TypeScript\Microsoft.TypeScript.targets(103,5): warning : The TypeScript Compiler was given no files for compilation, so it will skip compiling.
1> GeneratedJavascript=
1> C:\Users\Diego_Bertelli\Documents\Diego\Dev_Cordova\BlankCordovaApp2\BlankCordovaApp2>call "C:\Program Files (x86)\nodejs\"\nodevars.bat
1>C:\Program Files (x86)\MSBuild\Microsoft\VisualStudio\v12.0\CordovaTools\vs-mda-targets\Microsoft.MDA.targets(207,5): error : 'MySQL' n�o � reconhecido como um comando interno
1>C:\Program Files (x86)\MSBuild\Microsoft\VisualStudio\v12.0\CordovaTools\vs-mda-targets\Microsoft.MDA.targets(207,5): error : ou externo, um programa oper�vel ou um arquivo em lotes.
1>C:\Program Files (x86)\MSBuild\Microsoft\VisualStudio\v12.0\CordovaTools\vs-mda-targets\Microsoft.MDA.targets(207,5): error : 'MySQL' n�o � reconhecido como um comando interno
1>C:\Program Files (x86)\MSBuild\Microsoft\VisualStudio\v12.0\CordovaTools\vs-mda-targets\Microsoft.MDA.targets(207,5): error : ou externo, um programa oper�vel ou um arquivo em lotes.
1> Your environment has been set up for using Node.js 0.10.33 (ia32) and npm.
1> ------ Ensuring correct global installation of package from source package directory: C:\PROGRAM FILES (X86)\MICROSOFT VISUAL STUDIO 12.0\COMMON7\IDE\EXTENSIONS\2ACHJTAI.ITA\packages\vs-mda
========== Build: 0 succeeded, 1 failed, 0 up-to-date, 0 skipped ==========
========== Deploy: 0 succeeded, 0 failed, 0 skipped ==========
I don't think it's about the nodejs related issue.
Did a google translation and I think the error means "'MySQL' is not recognized as an internal command". So you have MySQL or related utilities installed on your machine, right? I am interested to know what it is.
This kind of error mainly cause because the command line cannot find the path to MySQL. something like "c:\program files(x86)\MySQL...\Bin".
[A workaround]So I will suggest you add the bin folder of MySQL server to PATH system environment variable. And try build again.
But I don't think Visual studio tools for Apache Cordova has any dependencies on MYSQL. That's why I treat above as a workaround.
I believe there must some local cache in folder like C:\Users\<yourname>\AppData\Roaming\npm\node_modules\ or C:\Users\<yourname>\AppData\Roaming\npm-cache\
What are the content in above folders? I think it's a valuable information for Visual Studio team to get it resolved.

Build doesn’t produce apk

I’m using Visual Studio Tools for Apache Cordova CTP3.1 on VS 2013. Building a simple Blank App template for Android. Build succeeds with no errors, but I can’t find compiled APK file anywhere! bin\Android\ folder contains empty Release and Debug folders. Below is my output from VS build. I don’t see the actual call to Cordova to do the Android build, should it be there? Ripple emulator works just fine.
Thank you.
Build output:
1>------ Build started: Project: BlankCordovaApp1, Configuration: Release Android ------
1>C:\Program Files (x86)\MSBuild\Microsoft\VisualStudio\v12.0\TypeScript\Microsoft.TypeScript.targets(95,5): warning : The TypeScript Compiler was given no files for compilation, so it will skip compiling.
1> GeneratedJavascript=
1> C:\Users\XXX\Documents\Visual Studio 2013\Projects\BlankCordovaApp1>call "C:\Program Files\nodejs\"\nodevars.bat
1> Your environment has been set up for using Node.js 0.12.0 (x64) and npm.
1> ------ Ensuring correct global installation of package from source package directory: C:\PROGRAM FILES (X86)\MICROSOFT VISUAL STUDIO 12.0\COMMON7\IDE\EXTENSIONS\DUZVVBQ3.2O1\packages\vs-mda
1> ------ Name from source package.json: vs-mda
1> ------ Version from source package.json: 0.1.75
1> ------ Current globally installed version: 0.1.75
1> ------ Package already installed globally at correct version.
========== Build: 1 succeeded, 0 failed, 0 up-to-date, 0 skipped ==========
To create apk, you need to select target as Device or Emulator. Apk is not created for Ripple because no package deployment is required, it is just launching the index.html in browser.

Unable to build Visual Studio 2015 Preview Codova Project in Release Mode - Getting Error - Command failed with exit code 8

I am using Visual 2015 Preview with Cordova Tools, am able to build, deploy application to device or VS Android Emulator without any issues in debug mode. Trouble I am having is when I do it release mode, whenever I am trying to build application in release mode I get below error
AppPath...\bld\Release\platforms\android\cordova\build.bat: Command failed with exit code 8 mode
In debug mode it works perfectly fine.
I have all environment variables set as follows as well
ADT_HOME - C:\Program Files (x86)\Android\android-sdk
ANT_HOME - C:\Program Files (x86)\Microsoft Visual Studio 14.0\Apps\apache-ant-1.9.3
JAVA_HOME - C:\Program Files (x86)\Java\jdk1.7.0_55
Path variable has been appended with %JAVA_HOME%\bin;%ADT_HOME%\tools;%ADT_HOME%\platform-tools;%ANT_HOME%\bin;
All these installation are part of default visual studio installation, except setting up environment variables.
Please let me know what needs to be done to resolve this in release mode.
I have already published my app in app store using VS 2015 preview with Cordova tools, I had to rebuilt my Developer machine/laptop and that's when all this trouble started. I need to publish an update to my app over this weekend but I am stuck now.
Below is Build Output for release mode
1>------ Build started: Project: PackagedInterviewApp, Configuration: Release Android ------
1>C:\Program Files (x86)\MSBuild\Microsoft\VisualStudio\v14.0\TypeScript\Microsoft.TypeScript.targets(96,5): warning : The TypeScript Compiler was given no files for compilation, so it will skip compiling.
1> GeneratedJavascript=
1> C:\TFS Application Path....>call "C:\Program Files (x86)\nodejs\"\nodevars.bat `enter code here`
1> Your environment has been set up for using Node.js 0.10.33 (ia32) and npm.
1> ------ Ensuring correct global installation of package from source package directory: C:\Program Files (x86)\Microsoft Visual Studio 14.0\Common7\IDE\Extensions\nxqc2vi5.kqy\packages\vs-mda
1>MDAVSCLI : error : C:\TFS Application Path....\bld\Release\platforms\android\cordova\build.bat: Command failed with exit code 8
========== Build: 0 succeeded, 1 failed, 0 up-to-date, 0 skipped ==========
Below is Build Output for Debug mode targeted to device or VS Android Emulator
1>------ Build started: Project: PackagedInterviewApp, Configuration: Debug Android ------
1>C:\Program Files (x86)\MSBuild\Microsoft\VisualStudio\v14.0\TypeScript\Microsoft.TypeScript.targets(96,5): warning : The TypeScript Compiler was given no files for compilation, so it will skip compiling.
1> GeneratedJavascript=
1> C:\TFS App Path...>call "C:\Program Files (x86)\nodejs\"\nodevars.bat
1> Your environment has been set up for using Node.js 0.10.33 (ia32) and npm.
1> ------ Ensuring correct global installation of package from source package directory: C:\Program Files (x86)\Microsoft Visual Studio 14.0\Common7\IDE\Extensions\nxqc2vi5.kqy\packages\vs-mda
2>------ Deploy started: Project: PackagedInterviewApp, Configuration: Debug Android ------
2>Starting launch process C:\Program Files (x86)\nodejs\node.exe ""C:\Users\....\AppData\Roaming\npm\node_modules\vs-mda\emulator.js"" --platform android --path "C:\TFS App Path...\bld\Debug" --deployTarget "target=169.254.220.177:5555" --language en-US --configuration debug
2> Generating config.xml from defaults for platform "android"
2> Calling plugman.prepare for platform "android"
2> Preparing android project
2> Processing configuration changes for plugins.
2> Iterating over installed plugins: []
2> Writing out cordova_plugins.js...
2> Wrote out Android application name to "Demo App"
2> This app does not have launcher icons defined
2> Wrote out Android package name to "io.cordova.myapp5fd4c4873c4d44e3a8d208242fbad585"
2> Running command: C:\TFS App Path...\bld\Debug\platforms\android\cordova\run.bat --nobuild --target=169.254.220.177:5555 --debug
2> Skipping build...
2> Built the following apk(s):
2> C:\TFS App Path...\bld\Debug\platforms\android\ant-build\CordovaApp-debug.apk
2> Using apk: C:\TFS App Path...\bld\Debug\platforms\android\ant-build\CordovaApp-debug.apk
2> Installing app on device...
2> Launching application...
2> LAUNCH SUCCESS
2> Command finished with error code 0: C:\TFS App Path...\bld\Debug\platforms\android\cordova\run.bat --nobuild,--target=169.254.220.177:5555,--debug
2>
========== Build: 1 succeeded, 0 failed, 0 up-to-date, 0 skipped ==========
========== Deploy: 1 succeeded, 0 failed, 0 skipped ==========
Turn Out to be very Minor Issue, I had migrated to new Dev Environment, I had ant.properties file which had this key == > key.store which points to the file path associated with key store, there was small typo in the path when I had changed it based on the new environment.
VS Studio shows above error, I had to increase the Build verbosity to diagnostic to show me the detail error, once I enabled the build log verbosity to diagnostic I was able to see the detail error.
U can increase verbosity over here
Tools > Options... > Projects and Solutions > Build and run
try this delete this directory
\bld\Release\platforms
For mine, it was the fact that I changed the ID from io.cordova.test to a single name, i.e. bob. I needed to change it to the format com.company.appname. As soon as I did that it worked.
I must credit #Amol Gote with his comment on enabling detailed build comments, without which I would not have seen this.

\npm\node_modules\vs-mda\vs-cli is not recognized as an internal or external command

Installed the Hybrid-App CTP. Downloaded the Backbone sample. Set my build to Windows phone and Emulator 720 P and tried to build. I get this error:
1>------ Build started: Project: BackboneTodo, Configuration: Debug Windows Phone ------
1>C:\Program Files (x86)\MSBuild\Microsoft\VisualStudio\v12.0\TypeScript\Microsoft.TypeScript.targets(90,5): warning : The TypeScript Compiler was given no files for compilation, so it will skip compiling.
1> Your environment has been set up for using Node.js 0.10.29 (x64) and npm.
1> ------ Ensuring correct global installation of package from source package directory: C:\Program Files (x86)\Microsoft Visual Studio 12.0\Common7\IDE\Extensions\n4ltjwgz.cbl\packages\vs-mda
1> '"C:\Users\<me>\AppData\Roaming\npm\node_modules\vs-mda\vs-cli"' is not recognized as an internal or external command,
1> operable program or batch file.
1>C:\Users\<me>\AppData\Roaming\npm\node_modules\vs-mda-targets\Microsoft.MDA.targets(68,5): error MSB3073: The command ""C:\Users\<me>\AppData\Roaming\npm\node_modules\vs-mda\vs-cli" build --platform "Windows Phone" --configuration "Debug" --projectDir . --projectName "BackboneTodo" --buildServerUrl "" --buildTarget "PhoneEmulator720P"" exited with code 9009.
========== Build: 0 succeeded, 1 failed, 0 up-to-date, 0 skipped ==========
The vs-cli does not exist in my \npm\node_modules\vs-mda directory. I tried to repair the CTP install with no luck.
Any other ideas on how to get this installed correctly?
It seems you Node installation was old, or corrupted. Try these steps:
1) Remove the CTP (this may take a while)
2) Remove node.js
3) Delete users\name\appdata\roaming\npm and users\name\appdata\roaming\npm-cache
4) Delete users\appdata.cordova
5) Re-install CTP
6) Open a sample application and build
It re-installs npm at this point and the vs-cli.cmd is there. In my case does not have spaces, and I did have those SDK's installed.
I've solved by removing C:\Users\Miquel\AppData\Roaming\npm\node_modules\vs-mda\node_modules\*.* and C:\Users\Miquel\AppData\Roaming\npm-cache\*.*
Then in cmd I went to C:\Users\Miquel\AppData\Roaming\npm\node_modules\vs-mda and ran:
npm install

Resources