lsjwzh / RecyclerViewPager

Deprecated
Apache License 2.0
3.53k stars 667 forks source link

Error:Module 'com.github.lsjwzh.RecyclerViewPager:tablayoutsupport:v1.1.2' depends on one or more Android Libraries but is a jar #142

Open commonsguy opened 7 years ago

commonsguy commented 7 years ago

To reproduce this problem:

  1. Create a new Android Studio 2.2.3 project, accepting all defaults, except use the "Empty Activity" template.

  2. Add both RecyclerViewPager dependencies to app/build.gradle:

repositories {
  maven { url "https://jitpack.io" }
}

dependencies {
  compile fileTree(dir: 'libs', include: ['*.jar'])
  androidTestCompile('com.android.support.test.espresso:espresso-core:2.2.2', {
    exclude group: 'com.android.support', module: 'support-annotations'
  })
  compile 'com.android.support:appcompat-v7:25.1.0'
  compile 'com.github.lsjwzh.RecyclerViewPager:lib:v1.1.2'
  compile 'com.github.lsjwzh.RecyclerViewPager:tablayoutsupport:v1.1.2'
  testCompile 'junit:junit:4.12'
}

You then get the error when syncing the project with the Gradle build files, or via gradle clean assembleDebug.

Skullper commented 7 years ago

Is someone already fixed this issue?

sokarcreative commented 7 years ago

According to this issue : https://github.com/hotchemi/PermissionsDispatcher/issues/35 Use compile 'com.github.lsjwzh.RecyclerViewPager:tablayoutsupport:v1.1.2@aar' instead of compile 'com.github.lsjwzh.RecyclerViewPager:tablayoutsupport:v1.1.2' It seems to work for me. Hope it helps !

Skullper commented 7 years ago

@sokarcreative Yeah! It works) Thx