googleads-mobile-unity icon indicating copy to clipboard operation
googleads-mobile-unity copied to clipboard

Undefined GADUGetAdErrorCode

Open adibacco opened this issue 2 years ago • 10 comments

[REQUIRED] Step 1: Describe your environment

  • Unity version: 2022.1.15f1
  • Google Mobile Ads Unity plugin version: 7.1.0
  • Platform: Android
  • Platform OS version: _____ (eg iOS 10, Android 9)
  • Any specific devices issue occurs on: _____
  • Mediation ad networks used, and their versions: _____

[REQUIRED] Step 2: Describe the problem

Steps to reproduce:

I get errors while building, a lot of undefined:

Building Library\Bee\artifacts\Android\d8kzr\libil2cpp.so failed with output:
Library/Bee/artifacts/Android/d8kzr/mjuk_ileAds.iOS.o: In function `Externs_GADUGetAdErrorCode_m13BEECB31CB8B8744138784CD04127D0FC2C7E79':
C:/Users/adiba/Documents/Apps/UnityProjects/LettersTracingClassic_174_a/Library/Bee/artifacts/Android/il2cppOutput/cpp/GoogleMobileAds.iOS.cpp:7726: undefined reference to `GADUGetAdErrorCode'
C:/Users/adiba/Documents/Apps/UnityProjects/LettersTracingClassic_174_a/Library/Bee/artifacts/Android/il2cppOutput/cpp/GoogleMobileAds.iOS.cpp:7726: undefined reference to `GADUGetAdErrorCode'
Library/Bee/artifacts/Android/d8kzr/mjuk_ileAds.iOS.o: In function `Externs_GADUGetAdErrorDomain_m6348FD0DD5FA3C6641D5F1D2F02D79DF4341D223':
C:/Users/adiba/Documents/Apps/UnityProjects/LettersTracingClassic_174_a/Library/Bee/artifacts/Android/il2cppOutput/cpp/GoogleMobileAds.iOS.cpp:7736: undefined reference to `GADUGetAdErrorDomain'
C:/Users/adiba/Documents/Apps/UnityProjects/LettersTracingClassic_174_a/Library/Bee/artifacts/Android/il2cppOutput/cpp/GoogleMobileAds.iOS.cpp:7736: undefined reference to `GADUGetAdErrorDomain'
Library/Bee/artifacts/Android/d8kzr/mjuk_ileAds.iOS.o: In function `Externs_GADUGetAdErrorMessage_mB01229122C55C1FACC41DC48B56AEEB94657397A':

Relevant Code:

adibacco avatar Sep 06 '22 20:09 adibacco

Hi @adibacco,

This is an issue relating to the External Dependency Manager. You should review your settings and make sure the needed cocoapods are being imported. My guess is it is failing to load, and you should see the errors when doing a Force Resolve if you look in the comments.

Hope this helps. If not, let me know your settings and log files and I will take another look, Nick

NVentimiglia avatar Sep 06 '22 23:09 NVentimiglia

Hi @NVentimiglia , thank you for your support:

  1. I'm compiling for Android why it is complainig about GoogleMobileAds.iOS.cpp
  2. I omitted that I had to change the link.xml in GoogleMobileAds to fix another problem. I added these lines:
<assembly fullname="GoogleMobileAds.Unity" ignoreIfMissing="1" preserve="nothing">
</assembly>
  1. The force resolve completes without any problem

See https://forum.unity.com/threads/3-building-error-code.1125641/ for a comment by Josh Peterson on the issue.

adibacco avatar Sep 08 '22 20:09 adibacco

Dear @NVentimiglia , it is very easy to reproduce the problem. Just create a new 2D Unity project with Unity 2022.1.15f1, then, import GoogleMobileAds 7.1.0 You will find that it compiles fine. Now change the scripting backend from Mono to IL2CPP and you will get my same error.

adibacco avatar Sep 09 '22 21:09 adibacco

U should

On Tue, 6 Sep 2565 BE at 16:13, adibacco @.***> wrote:

[REQUIRED] Step 1: Describe your environment

  • Unity version: 2022.1.15f1
  • Google Mobile Ads Unity plugin version: 7.1.0
  • Platform: Android
  • Platform OS version: _____ (eg iOS 10, Android 9)
  • Any specific devices issue occurs on: _____
  • Mediation ad networks used, and their versions: _____

[REQUIRED] Step 2: Describe the problem Steps to reproduce:

I get errors while building, a lot of undefined:

Building Library\Bee\artifacts\Android\d8kzr\libil2cpp.so failed with output: Library/Bee/artifacts/Android/d8kzr/mjuk_ileAds.iOS.o: In function Externs_GADUGetAdErrorCode_m13BEECB31CB8B8744138784CD04127D0FC2C7E79': C:/Users/adiba/Documents/Apps/UnityProjects/LettersTracingClassic_174_a/Library/Bee/artifacts/Android/il2cppOutput/cpp/GoogleMobileAds.iOS.cpp:7726: undefined reference to GADUGetAdErrorCode' C:/Users/adiba/Documents/Apps/UnityProjects/LettersTracingClassic_174_a/Library/Bee/artifacts/Android/il2cppOutput/cpp/GoogleMobileAds.iOS.cpp:7726: undefined reference to GADUGetAdErrorCode' Library/Bee/artifacts/Android/d8kzr/mjuk_ileAds.iOS.o: In function Externs_GADUGetAdErrorDomain_m6348FD0DD5FA3C6641D5F1D2F02D79DF4341D223': C:/Users/adiba/Documents/Apps/UnityProjects/LettersTracingClassic_174_a/Library/Bee/artifacts/Android/il2cppOutput/cpp/GoogleMobileAds.iOS.cpp:7736: undefined reference to GADUGetAdErrorDomain' C:/Users/adiba/Documents/Apps/UnityProjects/LettersTracingClassic_174_a/Library/Bee/artifacts/Android/il2cppOutput/cpp/GoogleMobileAds.iOS.cpp:7736: undefined reference to GADUGetAdErrorDomain' Library/Bee/artifacts/Android/d8kzr/mjuk_ileAds.iOS.o: In function `Externs_GADUGetAdErrorMessage_mB01229122C55C1FACC41DC48B56AEEB94657397A':

Relevant Code:

— Reply to this email directly, view it on GitHub https://github.com/googleads/googleads-mobile-unity/issues/2281, or unsubscribe https://github.com/notifications/unsubscribe-auth/ACHE5IIJKHRFLPQP5OHE7ILV46QVNANCNFSM6AAAAAAQGE2WAM . You are receiving this because you are subscribed to this thread.Message ID: @.***>

-- Kimberly Ann Collins

kimcollin avatar Sep 09 '22 21:09 kimcollin

@kimcollin , I didn't understand your message

adibacco avatar Sep 09 '22 21:09 adibacco

I also get the same problem with Unity 2022.1.15f1 importing GoogleMobileAds 7.2.0. My project is completely empty 2D project. If I select Mono as scripting backend it compiles fine, if I select il2cpp then I get the undefined errors.

adibacco avatar Sep 12 '22 18:09 adibacco

Hi @NVentimiglia , can we help you sorting out the problem like providing more info? It is very unlikely that a simple 2d project completely empty is not able to compile with IL2CPP?

adibacco avatar Sep 15 '22 05:09 adibacco

Anyone had some success ?

adibacco avatar Sep 19 '22 20:09 adibacco

And the Google leave us without any help?

adibacco avatar Sep 20 '22 21:09 adibacco

try changing unity version. it is wise not to waste time.

MuhammadWaqasOfficial avatar Sep 21 '22 12:09 MuhammadWaqasOfficial

The same error in 2022. Works fine in 2021.

hippogamesunity avatar Oct 25 '22 10:10 hippogamesunity

Any chance that this plugin will ever work with unity 2022? The problem is easy to reproduce:

I also get the same problem with Unity 2022.1.15f1 importing GoogleMobileAds 7.2.0. My project is completely empty 2D project.
If I select Mono as scripting backend it compiles fine, if I select il2cpp then I get the undefined errors.

adibacco avatar Nov 07 '22 20:11 adibacco

@NVentimiglia

hippogamesunity avatar Nov 07 '22 20:11 hippogamesunity

@NVentimiglia are you looking at the problem? Would you like any info or help?

adibacco avatar Dec 02 '22 22:12 adibacco

I'm experiencing the exact same issue - has anyone been able to find a solution to this problem?

Tokyomage avatar Dec 06 '22 01:12 Tokyomage

I don't think Google is willing to give support or any help on this product. Better to choose an alternative to Google Mobile Ads Plugin for Unity.

adibacco avatar Dec 06 '22 05:12 adibacco

I'm experiencing the exact same issue - has anyone been able to find a solution to this problem?

Hi, just use Unity 2021.

hippogamesunity avatar Dec 06 '22 07:12 hippogamesunity

I install Burst from unity package manager. undefined reference to GADUGetAdErrorCode compile error is resolved.

if1live avatar Dec 29 '22 09:12 if1live

The same error occurred in Unity 2022.2.2f1 and Burst v1.8.2. Non reproduced in Unity 2022.2.1f1 and Burst v1.7.4.

catmuzzle avatar Jan 19 '23 11:01 catmuzzle

Unity QA Team shared the comment on the below.

This issue is already fixed in 2021.3.18f1, 2022.2.5f1, 2023.1.0a21, and above.

catmuzzle avatar Feb 08 '23 11:02 catmuzzle

@adibacco Hi, I`m having the same problem. I changed some stuff in link.xml file to solve another problem and then the same errors that you mentioned occured. Tried everything but no luck. Did you solve it?

Using Unity 2022.1.7f1

Mert-dot avatar Feb 08 '23 11:02 Mert-dot

Hi

GADUGetAdErrorCode Is Google Mobile Ads Unity plugin code. This suggests to me that the '.a' file is not being included in the iOS build. Can you try reinstalling the package and verifying that the .a file is being included in the xcode project?

NVentimiglia avatar Feb 22 '23 02:02 NVentimiglia

Unity QA Team shared the comment on the below.

This issue is already fixed in 2021.3.18f1, 2022.2.5f1, 2023.1.0a21, and above.

Thank You. I upgraded it to Unity2022.2.9f1 and now it works!

imannms000 avatar Mar 05 '23 18:03 imannms000