0

I am trying to build my android app using Phonegap Build, but I am getting this error

Error - One of your plugins required the gradle android build tool to build

What am I missing here?

Matt
  • 33,328
  • 25
  • 83
  • 97

1 Answers1

1

Cordova/Phonegap switched to using Gradle instead of Ant for its build tool. Gradle allows plugins to dynamically request library dependencies rather than have to bundle them as JARs, so newer plugins tend to prefer Gradle as it plays better alongside other plugins.

AFAIK Ant is still the default for Phonegap Build (see here), but you can specify Gradle using the following preference:

<preference name="android-build-tool" value="gradle" />
DaveAlden
  • 30,083
  • 11
  • 93
  • 155
  • @DaveAlden I am working on ionic i am having error in regarding multidex in ionic I thought adding **gradle** will help me by add this line`` to my config.xml but i face same here how to use gradle in ionic here is my question http://stackoverflow.com/questions/37538143/ionic-build-android-command-fails-with-an-exception-after-trying-to-add-ngcordov/37539362#37539362 – Mohan Gopi May 31 '16 at 08:32
  • @MohanGopi from screenshot in your question, it looks like you are building locally. This preference is only for Phonegap Build and will have no effect in local builds, which now use Gradle by default anyway. – DaveAlden May 31 '16 at 09:34