这个问题已被多次回答,但我仍然无法弄清楚如何解决它。我在build.gradle compile 'com.android.support:appcompat-v7:25.3.1'
中遇到此错误。我不知道我需要在build.gradle中添加什么以使其工作。我有一个完整的依赖树,但我不知道我需要改变什么或如何做它
compile - Classpath for compiling the main sources.
+--- com.android.support:appcompat-v7:25.3.1
| +--- com.android.support:support-annotations:25.3.1
| +--- com.android.support:support-v4:25.3.1
| | +--- com.android.support:support-compat:25.3.1
| | | \--- com.android.support:support-annotations:25.3.1
| | +--- com.android.support:support-media-compat:25.3.1
| | | +--- com.android.support:support-annotations:25.3.1
| | | \--- com.android.support:support-compat:25.3.1 (*)
| | +--- com.android.support:support-core-utils:25.3.1
| | | +--- com.android.support:support-annotations:25.3.1
| | | \--- com.android.support:support-compat:25.3.1 (*)
| | +--- com.android.support:support-core-ui:25.3.1
| | | +--- com.android.support:support-annotations:25.3.1
| | | \--- com.android.support:support-compat:25.3.1 (*)
| | \--- com.android.support:support-fragment:25.3.1
| | +--- com.android.support:support-compat:25.3.1 (*)
| | +--- com.android.support:support-media-compat:25.3.1 (*)
| | +--- com.android.support:support-core-ui:25.3.1 (*)
| | \--- com.android.support:support-core-utils:25.3.1 (*)
| +--- com.android.support:support-vector-drawable:25.3.1
| | +--- com.android.support:support-annotations:25.3.1
| | \--- com.android.support:support-compat:25.3.1 (*)
| \--- com.android.support:animated-vector-drawable:25.3.1
| \--- com.android.support:support-vector-drawable:25.3.1 (*)
+--- com.android.support:support-v4:25.3.1 (*)
+--- com.google.firebase:firebase-database:10.2.0
| +--- com.google.android.gms:play-services-basement:10.2.0
| | \--- com.android.support:support-v4:24.0.0 -> 25.3.1 (*)
| +--- com.google.firebase:firebase-database-connection:10.2.0
| | +--- com.google.android.gms:play-services-basement:10.2.0 (*)
| | \--- com.google.firebase:firebase-common:10.2.0
| | +--- com.google.android.gms:play-services-basement:10.2.0 (*)
| | \--- com.google.android.gms:play-services-tasks:10.2.0
| | \--- com.google.android.gms:play-services-basement:10.2.0 (*)
| +--- com.google.firebase:firebase-common:10.2.0 (*)
| \--- com.google.android.gms:play-services-tasks:10.2.0 (*)
+--- com.sromku:simple-storage:1.2.0
+--- com.squareup.picasso:picasso:2.5.2
+--- com.android.support:recyclerview-v7:25.3.1
| +--- com.android.support:support-annotations:25.3.1
| +--- com.android.support:support-compat:25.3.1 (*)
| \--- com.android.support:support-core-ui:25.3.1 (*)
+--- at.blogc:expandabletextview:1.0.3
+--- it.neokree:MaterialTabs:0.11
| +--- com.github.markushi:android-ui:1.2
| \--- com.android.support:appcompat-v7:21.0.3 -> 25.3.1 (*)
+--- project :android-pdf-viewer
| \--- com.github.barteksc:pdfium-android:1.5.0
| \--- com.android.support:support-v4:21.0.3 -> 25.3.1 (*)
\--- com.google.firebase:firebase-core:10.2.0
\--- com.google.firebase:firebase-analytics:10.2.0
+--- com.google.android.gms:play-services-basement:10.2.0 (*)
+--- com.google.firebase:firebase-common:10.2.0 (*)
\--- com.google.firebase:firebase-analytics-impl:10.2.0
+--- com.google.android.gms:play-services-basement:10.2.0 (*)
+--- com.google.firebase:firebase-iid:10.2.0
| +--- com.google.android.gms:play-services-basement:10.2.0 (*)
| \--- com.google.firebase:firebase-common:10.2.0 (*)
+--- com.google.firebase:firebase-common:10.2.0 (*)
\--- com.google.android.gms:play-services-tasks:10.2.0 (*)
答案 0 :(得分:1)
可能是你的pdf库的问题。
+--- project :android-pdf-viewer
| \--- com.github.barteksc:pdfium-android:1.5.0
| \--- com.android.support:support-v4:21.0.3 -> 25.3.1 (*)
它仍然使用支持库v4版本21.0.3。
您可以尝试将pdf库升级到1.7.0
\--- com.github.barteksc:pdfium-android:1.7.0
\--- com.android.support:support-v4:25.3.1 (*)
或者在25.3.1
build.gradle
compile 'com.github.barteksc:pdfium-android:1.5.0'
compile 'com.android.support:support-v4:25.3.1'