07-02 03:26
Notice
Recent Posts
Recent Comments
07-02 03:26
«   2024/07   »
1 2 3 4 5 6
7 8 9 10 11 12 13
14 15 16 17 18 19 20
21 22 23 24 25 26 27
28 29 30 31
Archives
Today
Total
관리 메뉴

pear

[android] solved Duplicate class android.support.v4.app.INotificationSideChannel found in modules core-1.9.0-runtime 본문

android

[android] solved Duplicate class android.support.v4.app.INotificationSideChannel found in modules core-1.9.0-runtime

pearlab 2023. 12. 11. 18:25

 

오래된 외부 라이브러리를 사용 할때 

androidx.core 와 Duplicate 문제가 발생 할 때가 있다.

 

 

 

gradle.properties 파일에 옵션을 추가해주면 해결 될 때가 있다.

android.enableJetifier=true

 

  • android.enableJetifier: 이 플래그가 true로 설정되면 Android 플러그인에서 자동으로 기존 타사 라이브러리를 이전하여 바이너리를 다시 작성해 AndroidX 종속 항목을 사용합니다. 지정하지 않으면 플래그는 기본적으로 false입니다.

 

원인은 구버전과 충돌이 발생하는데 enableJetifier 플래그를 사용하면 빌드시 최신 버전만 남기는 마이그래션을 지원하여 해결되는 것으로 보인다.

 

Duplicate class android.support.v4.app.INotificationSideChannel found in modules core-1.9.0-runtime (androidx.core:core:1.9.0) and support-compat-26.1.0-runtime (com.android.support:support-compat:26.1.0)
Duplicate class android.support.v4.app.INotificationSideChannel$Stub found in modules core-1.9.0-runtime (androidx.core:core:1.9.0) and support-compat-26.1.0-runtime (com.android.support:support-compat:26.1.0)
Duplicate class android.support.v4.app.INotificationSideChannel$Stub$Proxy found in modules core-1.9.0-runtime (androidx.core:core:1.9.0) and support-compat-26.1.0-runtime (com.android.support:support-compat:26.1.0)
Duplicate class android.support.v4.os.IResultReceiver found in modules core-1.9.0-runtime (androidx.core:core:1.9.0) and support-compat-26.1.0-runtime (com.android.support:support-compat:26.1.0)
Duplicate class android.support.v4.os.IResultReceiver$Stub found in modules core-1.9.0-runtime (androidx.core:core:1.9.0) and support-compat-26.1.0-runtime (com.android.support:support-compat:26.1.0)
Duplicate class android.support.v4.os.IResultReceiver$Stub$Proxy found in modules core-1.9.0-runtime (androidx.core:core:1.9.0) and support-compat-26.1.0-runtime (com.android.support:support-compat:26.1.0)
Duplicate class android.support.v4.os.ResultReceiver found in modules core-1.9.0-runtime (androidx.core:core:1.9.0) and support-compat-26.1.0-runtime (com.android.support:support-compat:26.1.0)
Duplicate class android.support.v4.os.ResultReceiver$1 found in modules core-1.9.0-runtime (androidx.core:core:1.9.0) and support-compat-26.1.0-runtime (com.android.support:support-compat:26.1.0)
Duplicate class android.support.v4.os.ResultReceiver$MyResultReceiver found in modules core-1.9.0-runtime (androidx.core:core:1.9.0) and support-compat-26.1.0-runtime (com.android.support:support-compat:26.1.0)
Duplicate class android.support.v4.os.ResultReceiver$MyRunnable found in modules core-1.9.0-runtime (androidx.core:core:1.9.0) and support-compat-26.1.0-runtime (com.android.support:support-compat:26.1.0)

Go to the documentation to learn how to Fix dependency resolution errors.

 

 

link

https://developer.android.com/jetpack/androidx?hl=ko

'android' 카테고리의 다른 글

[android]Extenal File Access(over android 10)  (0) 2023.12.19
[android]okhttp & Retrofit  (0) 2023.08.10
[android] Thread와 Handler  (0) 2023.08.09
[android] List View and Recycler View  (0) 2023.08.09
[android] Life Cycle  (0) 2023.08.09