Android annotation processor gradle error -


i writing android library plan use different projects. there annotation processor library writing used generate code based on annotation defined in previous library.

the project structure is:

project     -> app (the test app)     -> android library     -> annotation processor 

my android library depends on appcompat , support:design libraries. build.gradle is:

apply plugin: 'com.android.library'  android {     compilesdkversion 22     buildtoolsversion "23.0.0 rc2"      defaultconfig {         minsdkversion 17         targetsdkversion 22         versioncode 1         versionname "1.0"     }     buildtypes {         release {             minifyenabled false             proguardfiles getdefaultproguardfile('proguard-android.txt'), 'proguard-rules.pro'         }     } }  dependencies {     compile filetree(dir: 'libs', include: ['*.jar'])     compile 'com.android.support:appcompat-v7:22.2.0'     compile 'com.android.support:design:22.2.0'     compile files('libs/guava-18.0.jar') } 

and build.gradle annotation processor is:

apply plugin: 'java'  sourcesets {     main {         java {             srcdirs = ['src/main/java']         }     } }  dependencies {     compile filetree(dir: 'libs', include: ['*.jar'])     compile project(":lib") } 

the issue here when build project gives me following error:

failure: build failed exception.  * went wrong: not resolve dependencies configuration ':threepio-anno-proc:compile'.         > not find com.android.support:appcompat-v7:22.2.0.         searched in following locations:         https://jcenter.bintray.com/com/android/support/appcompat-v7/22.2.0/appcompat-v7-22.2.0.pom https://jcenter.bintray.com/com/android/support/appcompat-v7/22.2.0/appcompat-v7-22.2.0.jar required by: threepio:threepio-anno-proc:unspecified > threepio:lib:unspecified > not find com.android.support:design:22.2.0.         searched in following locations:         https://jcenter.bintray.com/com/android/support/design/22.2.0/design-22.2.0.pom https://jcenter.bintray.com/com/android/support/design/22.2.0/design-22.2.0.jar required by: threepio:threepio-anno-proc:unspecified > threepio:lib:unspecified 

it compiles if dependency of android library removed annotation processor module. means android library project able access support , design packages not annotation processor.


Comments

Popular posts from this blog

javascript - Using jquery append to add option values into a select element not working -

Android soft keyboard reverts to default keyboard on orientation change -

jquery - javascript onscroll fade same class but with different div -