pwa-builder / PWABuilder-CLI

Node.js tool for App Generation
Other
1.63k stars 142 forks source link

Android Build failure due to Cordova sub-dependencies. #292

Open ghhv opened 6 years ago

ghhv commented 6 years ago

During a build of the files generated by PWABuilder on Android Studio 3, there are numerous errors such as

Unable to resolve dependency for ':@debugAndroidTest/compileClasspath': Could not resolve project :CordovaLib. 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.

This is caused by the default lines in Android build.gradle debugCompile project(path: "CordovaLib", configuration: "debug") releaseCompile project(path: "CordovaLib", configuration: "release")

lines 242 and 243.

To resolve, comment these out and replace with compile project(':CordovaLib')

Solution found via https://stackoverflow.com/questions/47023068/unable-to-run-ionic-app-after-update-to-android-studio-3-0

Can the build files generated not include these as default? Or is the correct fix to install the dependencies?

lucaasrojas commented 5 years ago

@ghhv Thanks for opening a new issue. Could you check if the issue continues?