Visual Studio cordova工具build.bat命令失败,退出代码为1.您可能没有所需的环境或操作系统来构建此项目

时间:2015-08-21 09:38:22

标签: android visual-studio cordova cross-platform ionic

我一直在使用apache cordova工具为视觉工作室开发我的应用程序很长一段时间。 昨天我在发布模式下构建了我的应用程序。今天我尝试添加cordova-white-list插件并将更新的cordova添加到4.0。现在,visual studio完全无法构建应用程序。

输出:

调试

> 1>  ------ Build configuration options: --debug 1>  Running command:
> C:\Users\Hardik\Hybrid\Ashley\Ashley\platforms\android\cordova\build.bat
> --debug 1>  ANDROID_HOME=E:\android 1>  JAVA_HOME=C:\Program Files (x86)\Java\jdk1.7.0_55 1>  Running:
> C:\Users\Hardik\Hybrid\Ashley\Ashley\platforms\android\gradlew
> cdvBuildDebug -b
> C:\Users\Hardik\Hybrid\Ashley\Ashley\platforms\android\build.gradle
> -Dorg.gradle.daemon=true 1>  :preBuild 1>  :compileDebugNdk UP-TO-DATE 1>  :preDebugBuild 1>  :checkDebugManifest 1>  :CordovaLib:compileLint
> 1>  :CordovaLib:copyDebugLint UP-TO-DATE 1> 
> :CordovaLib:mergeDebugProguardFiles UP-TO-DATE 1> 
> :CordovaLib:preBuild 1>  :CordovaLib:preDebugBuild 1> 
> :CordovaLib:checkDebugManifest 1> 
> :CordovaLib:prepareDebugDependencies 1>  :CordovaLib:compileDebugAidl
> UP-TO-DATE 1>  :CordovaLib:compileDebugRenderscript UP-TO-DATE 1> 
> :CordovaLib:generateDebugBuildConfig UP-TO-DATE 1> 
> :CordovaLib:generateDebugAssets UP-TO-DATE 1> 
> :CordovaLib:mergeDebugAssets UP-TO-DATE 1> 
> :CordovaLib:generateDebugResValues UP-TO-DATE 1> 
> :CordovaLib:generateDebugResources UP-TO-DATE 1> 
> :CordovaLib:packageDebugResources UP-TO-DATE 1> 
> :CordovaLib:processDebugManifest UP-TO-DATE 1> 
> :CordovaLib:processDebugResources UP-TO-DATE 1> 
> :CordovaLib:generateDebugSources UP-TO-DATE 1> 
> :CordovaLib:compileDebugJava UP-TO-DATE 1> 
> :CordovaLib:processDebugJavaRes UP-TO-DATE 1> 
> :CordovaLib:packageDebugJar UP-TO-DATE 1>  :CordovaLib:compileDebugNdk
> UP-TO-DATE 1>  :CordovaLib:packageDebugJniLibs UP-TO-DATE 1> 
> :CordovaLib:packageDebugLocalJar UP-TO-DATE 1> 
> :CordovaLib:packageDebugRenderscript UP-TO-DATE 1> 
> :CordovaLib:bundleDebug UP-TO-DATE 1> 
> :com.google.playservices:google-play-services_lib:compileLint 1> 
> :com.google.playservices:google-play-services_lib:copyDebugLint
> UP-TO-DATE 1> 
> :com.google.playservices:google-play-services_lib:mergeDebugProguardFiles
> UP-TO-DATE 1> 
> :com.google.playservices:google-play-services_lib:preBuild 1> 
> :com.google.playservices:google-play-services_lib:preDebugBuild 1> 
> :com.google.playservices:google-play-services_lib:checkDebugManifest
> 1> 
> :com.google.playservices:google-play-services_lib:preDebugTestBuild 1>
> :com.google.playservices:google-play-services_lib:prepareAndroidCordovaLibUnspecifiedDebugLibrary
> UP-TO-DATE 1> 
> :com.google.playservices:google-play-services_lib:prepareDebugDependencies
> 1>  :com.google.playservices:google-play-services_lib:compileDebugAidl
> UP-TO-DATE 1> 
> :com.google.playservices:google-play-services_lib:compileDebugRenderscript
> UP-TO-DATE 1> 
> :com.google.playservices:google-play-services_lib:generateDebugBuildConfig
> UP-TO-DATE 1> 
> :com.google.playservices:google-play-services_lib:generateDebugAssets
> UP-TO-DATE 1> 
> :com.google.playservices:google-play-services_lib:mergeDebugAssets
> UP-TO-DATE 1> 
> :com.google.playservices:google-play-services_lib:generateDebugResValues
> UP-TO-DATE 1> 
> :com.google.playservices:google-play-services_lib:generateDebugResources
> UP-TO-DATE 1> 
> :com.google.playservices:google-play-services_lib:mergeDebugResources
> UP-TO-DATE 1> 
> :com.google.playservices:google-play-services_lib:processDebugManifest
> UP-TO-DATE 1> 
> :com.google.playservices:google-play-services_lib:processDebugResources
> UP-TO-DATE 1> 
> :com.google.playservices:google-play-services_lib:generateDebugSources
> UP-TO-DATE 1> 
> :com.google.playservices:google-play-services_lib:compileDebugJava
> UP-TO-DATE 1> 
> :com.google.playservices:google-play-services_lib:processDebugJavaRes
> UP-TO-DATE 1> 
> :com.google.playservices:google-play-services_lib:packageDebugJar
> UP-TO-DATE 1> 
> :com.google.playservices:google-play-services_lib:compileDebugNdk
> UP-TO-DATE 1> 
> :com.google.playservices:google-play-services_lib:packageDebugJniLibs
> UP-TO-DATE 1> 
> :com.google.playservices:google-play-services_lib:packageDebugLocalJar
> UP-TO-DATE 1> 
> :com.google.playservices:google-play-services_lib:packageDebugRenderscript
> UP-TO-DATE 1> 
> :com.google.playservices:google-play-services_lib:packageDebugResources
> UP-TO-DATE 1> 
> :com.google.playservices:google-play-services_lib:bundleDebug
> UP-TO-DATE 1> 
> :prepareAndroidComGooglePlayservicesGooglePlayServices_libUnspecifiedDebugLibrary
> UP-TO-DATE 1>  :prepareAndroidCordovaLibUnspecifiedDebugLibrary
> UP-TO-DATE 1>  :prepareDebugDependencies 1>  :compileDebugAidl
> UP-TO-DATE 1>  :compileDebugRenderscript UP-TO-DATE 1> 
> :generateDebugBuildConfig UP-TO-DATE 1>  :generateDebugAssets
> UP-TO-DATE 1>  :mergeDebugAssets UP-TO-DATE 1> 
> :generateDebugResValues UP-TO-DATE 1>  :generateDebugResources
> UP-TO-DATE 1>  :mergeDebugResources UP-TO-DATE 1> 
> :processDebugManifest UP-TO-DATE 1>  :processDebugResources UP-TO-DATE
> 1>  :generateDebugSources UP-TO-DATE 1>  :compileDebugJava FAILED 1>
> 1>  BUILD FAILED 1> 1>  Total time: 23.655 secs
> 

> 
> **1>  Command finished with error code 1: C:\Users\Hardik\Hybrid\Ashley\Ashley\platforms\android\cordova\build.bat
> --debug 1>ERROR building one of the platforms : error : C:\Users\Hardik\Hybrid\Ashley\Ashley\platforms\android\cordova\build.bat:
> Command failed with exit code 1 1>  You may not have the required
> environment or OS to build this project 1>MDAVSCLI : error :
> C:\Users\Hardik\Hybrid\Ashley\Ashley\platforms\android\cordova\build.bat:
> Command failed with exit code 1
>  Build: 0 succeeded, 1 failed, 0 up-to-date, 0 skipped **

1.我安装了API 22,21和19。

2.已经尝试清除cordova缓存。

3.昨天之前工作得非常好。

0 个答案:

没有答案