I'm trying to do cordova build android, it fails with
Could not determine the dependencies of task ':compileDebugJavaWithJavac'.
Could not resolve all task dependencies for configuration ':debugCompileClasspath'. Could not resolve project :CordovaLib. Required by: project : Project : declares a dependency from configuration 'debugCompile' to configuration 'debug' which is not declared in the descriptor for project :CordovaLib.
I came to know that if I replace these two lines
debugCompile(project(path: "CordovaLib", configuration: "debug"))
releaseCompile(project(path: "CordovaLib", configuration: "release"))
with this in android studio(directly in build.gradle)
compile project(':CordovaLib')
then it works, I mean it builds. But as the project is in Ionic / Cordova, when I try to build it with cordova build android, it fails with above error again, as the changes gets overwritten by Gradlebuilder.js file back to the above 2 lines debug & releasecompile.
I want to know what & where should I make changes in gradlebuilder.js, so I get those 2 lines replaced by
compile project(':CordovaLib')
Any help is appreciated.