navasmdc / MaterialDesignLibrary

This is a library with components of Android L to you use in android 2.2
Apache License 2.0
8.99k stars 2.22k forks source link

AndroidX #420

Open Chenyang0324 opened 5 years ago

Chenyang0324 commented 5 years ago

For anyone is facing AndroidX migration issue. try this. implementation 'com.github.Chenyang0324:MaterialDesignLibrary:1.10'

taar1 commented 5 years ago

I just tried it out but I still get this error:

ERROR: Unable to resolve dependency for ':app@googlePlayFlavorDebug/compileClasspath': Could not resolve com.android.support:support-v4:22.+.

Chenyang0324 commented 5 years ago

@taar1 Check if there is any other place is referencing support library. The app should be no longer referencing any support library if you are migrating to Android X.

taar1 commented 5 years ago

I just did another test. I commented this out: implementation 'com.github.Chenyang0324:MaterialDesignLibrary:1.10'

and I could build the app without error messages (well except the errors I get for not having the MaterialDesignLibrary in the project but references to it in the code). As soon as I uncomment it and try to build it I get this error:

ERROR: Unable to resolve dependency for ':app@googlePlayFlavorDebug/compileClasspath': Could not resolve com.android.support:support-v4:22.+. Show Details Affected Modules: app

ERROR: Unable to resolve dependency for ':app@googlePlayFlavorDebugAndroidTest/compileClasspath': Could not resolve com.android.support:support-v4:22.+. Show Details Affected Modules: app

ERROR: Unable to resolve dependency for ':app@googlePlayFlavorDebugUnitTest/compileClasspath': Could not resolve com.android.support:support-v4:22.+. Show Details Affected Modules: app

taar1 commented 5 years ago

I just looked at your fork and saw you still have a support-v4 dependency in there.

https://github.com/Chenyang0324/MaterialDesignLibrary/blob/master/MaterialDesignLibrary/MaterialDesign/build.gradle

dependencies { compile 'com.nineoldandroids:library:2.4.+' compile 'com.android.support:support-v4:22.+' compile fileTree(dir: 'libs', include: '*.jar') }

Could you remove that dependency and make a new version? I think after that it should build.