I’m doing a Gradle build with Unity 2019.4.21f1, target Android 10.0, and testing on a Nexus with Android 6.0.
I get these error when I try to initialize the Google Mobile Ads SDK for AdMob (among other places), and the SDK doesn’t work (device logs below). On an Android 10 I tried this error is not there and the SDK works.
Any suggestions for how to go about fixing this?
** Logs When Initializing **
03-03 21:14:45.986 17696 17740 I Unity : Will initialize AdMob
03-03 21:14:45.986 17696 17740 I Unity : AdMobAdHelper:Setup(AdManager, Boolean)
03-03 21:14:45.986 17696 17740 I Unity : AdManager:Start()
03-03 21:14:45.986 17696 17740 I Unity :
03-03 21:14:45.986 17696 17740 I Unity : (Filename: ./Runtime/Export/Debug/Debug.bindings.h Line: 39)
03-03 21:14:45.986 17696 17740 I Unity :
03-03 21:14:46.033 17696 17740 E linker : readlink(‘/proc/self/fd/67’) failed: Permission denied [fd=67]
03-03 21:14:46.033 17696 17740 E linker : warning: unable to get realpath for the library “/system/framework/oat/arm64/com.android.location.provider.odex”. Will use given name.
03-03 21:14:46.035 17696 17740 E linker : readlink(‘/proc/self/fd/67’) failed: Permission denied [fd=67]
03-03 21:14:46.035 17696 17740 E linker : warning: unable to get realpath for the library “/system/framework/oat/arm64/com.android.media.remotedisplay.odex”. Will use given name.
03-03 21:14:46.039 17696 17740 E linker : readlink(‘/proc/self/fd/67’) failed: Permission denied [fd=67]
03-03 21:14:46.039 17696 17740 E linker : warning: unable to get realpath for the library “/data/app/com.google.android.gms-2/oat/arm64/base.odex”. Will use given name.
03-03 21:14:46.148 17696 17740 I DynamiteModule: Considering local module com.google.android.gms.ads.dynamite:0 and remote module com.google.android.gms.ads.dynamite:204890103
03-03 21:14:46.150 17696 17740 I DynamiteModule: Selected remote version of com.google.android.gms.ads.dynamite, version >= 204890103
03-03 21:14:46.158 17696 17740 D DynamitePackage: Instantiated singleton DynamitePackage.
03-03 21:14:46.158 17696 17740 D DynamitePackage: Instantiating com.google.android.gms.ads.ChimeraMobileAdsSettingManagerCreatorImpl
** Logs When Loading an Ad Afterwards **
03-03 21:15:01.426 17696 17696 E Ads : ### This app is using a lightweight version of the Google Mobile Ads SDK that requires the latest Google Play services to be installed, but Google Play services is either missing or out of date.
03-03 21:15:01.437 17696 17893 I Unity : AdFailedToLoad: Invalid request
03-03 21:15:01.437 17696 17893 I Unity : System.EventHandler1:Invoke(Object, TEventArgs) 03-03 21:15:01.437 17696 17893 I Unity : System.EventHandler1:Invoke(Object, TEventArgs)
03-03 21:15:01.437 17696 17893 I Unity : System.Reflection.MonoMethod:Invoke(Object, BindingFlags, Binder, Object[ ], CultureInfo)
03-03 21:15:01.437 17696 17893 I Unity : UnityEngine.AndroidJavaProxy:Invoke(String, Object[ ])
03-03 21:15:01.437 17696 17893 I Unity : UnityEngine._AndroidJNIHelper:InvokeJavaProxyMethod(AndroidJavaProxy, IntPtr, IntPtr)