Android library project is not getting included in Gradle build -
this query continuation previous question did not answer requesting here. previous question can found here (android - gradle multiproject include , exclude libraries)
with productflavors, 1 can avoid include , exclude library projects main project. in case, projecta----- mainproject,
liba ---- library project,
libb ---- library project,
....
liba classes used in projecta. libb classes not used where. library required part of projecta.apk(mentioned in projecta manifest file)
after "gradle build", in build/classes/flavor/debug or release/packagename/.. liba classes there. libb classes not there in build/classes/.. path , libb functionality not working. (note: same working fine eclipse build)
libb classes getting included if importing libb classes in projecta libb plug , play type library , not required time.
libb build.gradle file follows:
buildscript { repositories {mavencentral()} dependencies { classpath 'com.android.tools.build:gradle:0.3'} } apply plugin: 'android-library' android { compilesdkversion 14 sourcesets { main { manifest {srcfile 'androidmanifest.xml'} java {srcdir 'src'} res {srcdir 'res'} assets {srcdir 'assets'} resources {srcdir 'src'} jni {srcdir 'jni'} } } task configurerelease << { proguard.enabled = true } }
how include libb? please guide me resolving issue.
thanks in advance
you need add dependencies node...
dependencies { compile project(':libb') } android { xxx }
Comments
Post a Comment