본문 바로가기

Study/Unity

유니티 SNS 공유 빌드 에러 : android resource linking failed: unexpected element <queries> found in <manifest>

https://assetstore.unity.com/packages/tools/integration/native-share-for-android-ios-112731

 

Native Share for Android & iOS | 기능 통합 | Unity Asset Store

Use the Native Share for Android & iOS from yasirkula on your next project. Find this integration tool & more on the Unity Asset Store.

assetstore.unity.com

순간적 캡처로 어디든 공유할 수 있는 에셋.

예시 코드만 작성하면 되었는데 갑자기 빌드 에러가 떴다.

 

어쩌라는 거야... 디벨로퍼...

개발자가 올려놓은 해결책은 그냥 안드로이드 11용 빌드 링크만 딸랑 올려놔서 어쩔 줄 몰랐다.

그런데 빌드 에러 문구만 구글링했더니 바로 답 나옴;;;

 

https://android-developers.googleblog.com/2020/07/preparing-your-build-for-package-visibility-in-android-11.html 

 

Preparing your Gradle build for package visibility in Android 11

Posted by David Winer , Product Manager One of the central themes for Android 11 has been protecting user privacy. On Android 10 an...

android-developers.googleblog.com

안드로이드 11로 가면서 Gradle 버전의 오류로 인해 빌드가 안된 것.

그로 인해 핫픽스로 대책을 내놓았다.

 

유니티 Project Settings -> Player -> Build 란에 Custom Base Gradle Template 체크 

 

classpath 'com.android.tools.build:gradle:3.4.3'

Plugins -> Android 폴더에 baseProjectTemplate.gradle에 버전을 변경해주면 바로 해결된다.

나 같은 경우는 3.4.0 -> 3.4.3