Cordova build:命令失败,退出代码为8

时间:2015-03-12 09:11:24

标签: facebook cordova

我正在为Android构建手机间隙(Cordova 3.5)应用程序并试图实现Facebook登录。我已经安装了facebook插件然后我在connectPlugin.java文件中遇到错误然后我在我的项目中导入了facebook SDK库。在eclipse中显示的所有错误现在都消失了但是当我尝试运行'cordova build'时,构建失败并出现以下错误。

BUILD FAILED
D:\android-tool\sdk\tools\ant\build.xml:653: The following error occu
executing this line:
D:\android-tool\sdk\tools\ant\build.xml:698: null returned: 1

Total time: 12 seconds

D:\xampp\htdocs\android-app\refund_app\platforms\android\cordova\node
q.js:126
                    throw e;
                          ^
Error code 1 for command: cmd with args: /s,/c,ant,debug,-f,D:\xampp\
oid-app\refund_app\platforms\android\build.xml,-Dout.dir=ant-build,-D
e.dir=ant-gen
Error: D:\xampp\htdocs\android-app\refund_app\platforms\android\cordo
t: Command failed with exit code 8
    at ChildProcess.whenDone (C:\Users\USER\AppData\Roaming\npm\node_
dova\node_modules\cordova-lib\src\cordova\superspawn.js:135:23)
    at ChildProcess.emit (events.js:98:17)
    at maybeClose (child_process.js:756:16)
    at Process.ChildProcess._handle.onexit (child_process.js:823:5)

1 个答案:

答案 0 :(得分:0)

我自己解决了这个问题,实际上由于facebook SDK中的目录无效,构建失败了 mypath中/ Facebook的Android的SDK-3.23.0 \ Facebook的\ BIN \水库\紧缩 我从'crunch'文件夹中剪切了所有内容并将其粘贴在'res'文件夹下,然后删除了'crunch'文件夹。然后cordova构建开始工作。