简体   繁体   English

Phonegap Build Android:ReferenceError

[英]Phonegap Build Android: ReferenceError

I am building the app for android. 我正在构建Android的应用程序。 But then I see this: 但后来我看到了这个:

[ReferenceError: a is not defined]
exec: ant clean -f "/Users/chaitanya/BPEase/platforms/android/build.xml"
[ 'ant clean -f "/Users/chaitanya/BPEase/platforms/android/build.xml"',
  { [Error: Command failed: 
  BUILD FAILED
  /Users/chaitanya/BPEase/platforms/android/build.xml:90: Cannot find /Applications/eclipse/sdk/tools/ant/build.xml imported from /Users/chaitanya/BPEase/platforms/android/build.xml

  Total time: 0 seconds
  ] killed: false, code: 1, signal: null },
  'Buildfile: /Users/chaitanya/BPEase/platforms/android/build.xml\n',
  '\nBUILD FAILED\n/Users/chaitanya/BPEase/platforms/android/build.xml:90: Cannot find /Applications/eclipse/sdk/tools/ant/build.xml imported from /Users/chaitanya/BPEase/platforms/android/build.xml\n\nTotal time: 0 seconds\n' ]
Error executing "ant clean -f "/Users/chaitanya/BPEase/platforms/android/build.xml"": 
BUILD FAILED
/Users/chaitanya/BPEase/platforms/android/build.xml:90: Cannot find /Applications/eclipse/sdk/tools/ant/build.xml imported from /Users/chaitanya/BPEase/platforms/android/build.xml

I have tried to reinstall cordova. 我试图重新安装cordova。 Does not give me a positive feedback. 不给我一个积极的反馈。 What should I do? 我该怎么办?

I had the same issue. 我遇到过同样的问题。 It would seem that there is a reference to the path to your adt bundle stored in the: /platforms/android/local.properties and the /platforms/android/Cordovalib/local.properties files. 似乎存在以下内容的引用:adt包的路径存储在: /platforms/android/local.properties/platforms/android/Cordovalib/local.properties文件中。 My issue was that, since these files were checked into source control, they were giving me a path that was configured for another environment. 我的问题是,由于这些文件被检入源代码控制,他们给了我一个为另一个环境配置的路径。 Modifying them to point to the correct path for my local machine did the trick for me. 修改它们以指向我本地机器的正确路径对我来说是个窍门。

Here's a link to a site that helped me figure it out: http://thelogbox.com/cannot-find-buildxml/ 这是一个帮助我解决问题的网站链接: http//thelogbox.com/cannot-find-buildxml/

you have different version of phonegap installed (maybe 3.4 and application wrote on 3.3). 你安装了不同版本的phonegap(可能是3.4,应用程序是在3.3上写的)。 you can change .cordova > config.json file and set the same version of phonegap (3.3) 你可以更改.cordova> config.json文件并设置相同版本的phonegap(3.3)

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM