블로그 이미지
Every unexpected event is a path to learning for you. blueasa

카테고리

분류 전체보기 (2797)
Unity3D (853)
Programming (479)
Server (33)
Unreal (4)
Gamebryo (56)
Tip & Tech (185)
협업 (61)
3DS Max (3)
Game (12)
Utility (68)
Etc (98)
Link (32)
Portfolio (19)
Subject (90)
iOS,OSX (55)
Android (14)
Linux (5)
잉여 프로젝트 (2)
게임이야기 (3)
Memories (20)
Interest (38)
Thinking (38)
한글 (30)
PaperCraft (5)
Animation (408)
Wallpaper (2)
재테크 (18)
Exercise (3)
나만의 맛집 (3)
냥이 (10)
육아 (16)
Total
Today
Yesterday

Unity 2021.3.16f1

External Dependency Manager 1.2.175

GoogleMobileAds 7.4.0

 

[빌드에러]

...

FAILURE: Build failed with an exception.

* What went wrong:
Execution failed for task ':launcher:dexBuilderRelease'.
> java.lang.UnsupportedOperationException: This feature requires ASM7

...

 

[해결]

gradle 버전이 낮아서 생기는 문제라고 한다.

Android 11이슈로 쓰던 gradle 버전이 com.android.tools.build:gradle:3.4.3 이었는데,

Unity 2021.3.16f1 기준 기본 버전이 com.android.tools.build:gradle:4.0.1 이어서 해당 버전을 사용하니 빌드가 잘된다.

다시 해보니 Unity 2021.3.16f1 기본 버전인 com.android.tools.build:gradle:4.0.1 이 빌드가 제대로 안돼서,

com.android.tools.build:gradle:4.0.1+로 수정하고 나서 제대로 되는 걸 확인했다.

(GoogleMobileAds 7.4.0이 gradle 4.0.1에서 에러나는걸로 봐서는 상위 버전 뭔가를 쓰는 것 같은데 무슨 버전을 쓰는지 모르겠어서 +를 붙였음)

 

[주의]

gradle 버전을 해당 Unity 엔진이 가지고 있는 버전보다 높게 올리면 아래와 같은 에러를 보게 된다.

지정한 gradle 버전을 사용하려면 맞는 gradle 플러그인 버전을 받아서 해당 위치에 넣어주거나,

현재 Unity 엔진이 가지고 있는 버전에 맞추거나 하자.

(난 받기 귀찮기도 하고, 협업을 하려면 다른 곳도 설치해줘야 되는 문제들로 인해서

  현재 Unity 버전이 지원하는(gradle 4.0.1) 걸로 셋팅 함)

FAILURE: Build failed with an exception.

* Where:
Build file 'C:\Project\git\GuitarGirl\Library\Bee\Android\Prj\IL2CPP\Gradle\launcher\build.gradle' line: 1

* What went wrong:
A problem occurred evaluating project ':launcher'.
> Failed to apply plugin [id 'com.android.internal.version-check']
   > Minimum supported Gradle version is 6.5. Current version is 6.1.1. If using the gradle wrapper, try editing the distributionUrl in C:\Project\git\GuitarGirl\Library\Bee\Android\Prj\IL2CPP\Gradle\gradle\wrapper\gradle-wrapper.properties to gradle-6.5-all.zip

 

[참고] https://stackoverflow.com/questions/68709559/nestmember-requires-asm7

 

NestMember requires ASM7

After update to Java 11 got an error in Android Studio by ./gradlew lintFooDebug command. * What went wrong: Execution failed for task ‘foo:syncDebugLibJars'. > NestMember requires ASM7 • Ran ./

stackoverflow.com

 

[gradle version 변경하기] https://blueasa.tistory.com/2703

 

[링크] Unity - Android Gradle Version 변경하기

[링크] https://drehzr.tistory.com/1022 Unity)Android Gradle Version Change Unity Android Gradle Version Change Unity 에서 Android의 Gradle의 버전을 변경을 해야하는 경우가 생겨서 이렇게 포스팅하게 되었다. Project Setting 의

blueasa.tistory.com

 

[gradle cache 삭제하기] https://happyryu.tistory.com/138

 

유니티 CommandInvokationFailure 해결방법

혹시나 이런 에러가 뜬다면? 아놔 참내.. 대빠 짜증나네요. 열나게 찾아보다가 유니티 버젼업도 해보고 Admob plugin 다시 지웠다가 깔았따 삽질하다가 드디어 찾았습니다. C:\Users\[윈도우계정 폴더]

happyryu.tistory.com

 

반응형
Posted by blueasa
, |

Untiy 2021.3.14f1

GoogleMobileAds 7.3.0

----

 

Unity 2021로 엔진 업데이트를 하고 빌드해보려는데 에러가 나서 보니 GoogleMobileAds 7.3.0 관련 이슈인 것 같다.

(GoogleMobileAds 7.2.0은 빌드 잘됨)

검색해보니 아래와 같은 해결책이 나온다.

 

- 간단히 말하면 Unity 2021에서 GoogleMobileAds 7.3.0을 쓰려면 gradle 버전 업데이트 하라고 한다. (아래 내용 따라하라고 함)

- 그래서 난 일단 GoogleMobileAds 7.2.0으로 버전을 내렸다(?)

 

--------------------------------------------------------------------------------------------------------------------------------

·8 mo. ago·edited 8 mo. ago

Yo so I found a way to solve this, assuming you are using applovin or charboost , what I did was:

  • Delete resolved libraries : Assets> External Dependancy Manager > Android resolver > Delete resolve libs
  • in player settings > pulishing settings uncheck all the one under build
  • Download gradle 6.9
  • Prefrences > external tools > uncheck gradle and browse to the installed gradle
  • Assets> External Dependancy Manager > Android resolver > Force resolve
  • then player settings > pulishing settings check all the ones you uncheck plus Custom Base Gradle Template
  • edit the file Asstes\Plugins\Android\baseProjectTemplate.gradle
  • change target api level to 31
  • change the line that looks like classpath 'com.android.tools.build:gradle:yourversion' to classpath 'com.android.tools.build:gradle:4.2.0'

Build now it works. the funny thing is that gradle is 6.9 and com.adroid.tools.build:gradle: is 4.2.0 but it works.

[출처] https://www.reddit.com/r/Unity3D/comments/tktc13/i_need_help_asap/

 

I NEED HELP ASAP

**Hello everyone. I've been trying to build my game but I get these errors:** *...

www.reddit.com

--------------------------------------------------------------------------------------------------------------------------------

Hello. I solved my problem this way.
Download the latest Gradle version here.
https://gradle.org/releases/

Place the unzipped Gradle file in the following location
/Applications/Unity/Hub/Editor/2021.3.12f1/PlaybackEngines/AndroidPlayer/Tools/gradle/
Please note that 2021.3.12f1 is the editor version and should be replaced with your own environment.

Next, open Unity and change the Gradle to be used.
From the top menu, select Unity > Preferences and open External Tools.

Uncheck the box marked "Gradle Installed with Unity (recommended)" and enter the path to the Gradle you just placed.

Now the Gradle used for building has been switched to a different version.
If there are no problems with the version, you should now be able to build Android.

 

[출처] https://github.com/googleads/googleads-mobile-unity/issues/2390

 

This feature requires ASM7 · Issue #2390 · googleads/googleads-mobile-unity

[REQUIRED] Step 1: Describe your environment Unity version: 2021.3.12f1 Google Mobile Ads Unity plugin version: 7.3.0 Platform: Unity Editor Platform OS version: Android 12 Any specific devices iss...

github.com

 

반응형
Posted by blueasa
, |