Android Question Errors adding AdMob to my app

Alberto Michelis

Well-Known Member
Licensed User
B4A 8.80
Having followed all steps to add AdMob to my app.
Getting errors I downloaded and updated the SDK Manager and Install all of it suggests.
Recompile my app without AdMob is OK

Compiling with AdMob
Im gettin this errors...

Generando el fichero R. Error
C:\b4android\SourceCode\PortIt_AdMov\Objects\bin\extra\res3\res\values\values.xml:36: error: Attribute "fontProviderFetchStrategy" already defined with incompatible format.
C:\b4android\SourceCode\PortIt_AdMov\Objects\bin\extra\res8\res\values\values.xml:42: Original attribute defined here.
C:\b4android\SourceCode\PortIt_AdMov\Objects\bin\extra\res3\res\values\values.xml:51: error: Attribute "fontProviderFetchTimeout" already defined with incompatible format.
C:\b4android\SourceCode\PortIt_AdMov\Objects\bin\extra\res8\res\values\values.xml:54: Original attribute defined here.
C:\b4android\SourceCode\PortIt_AdMov\Objects\bin\extra\res3\res\values\values.xml:61: error: Attribute "fontStyle" already defined with incompatible format.
C:\b4android\SourceCode\PortIt_AdMov\Objects\bin\extra\res8\res\values\values.xml:62: Original attribute defined here.

What can I do?
 

Alberto Michelis

Well-Known Member
Licensed User
Ive installed a new AndroidSDK from scratch
Run the new SDK manager and installed all
Test to compile with the new AndroidSDK many of my apps and all is ok
Then add again the AdMob, compile and got this errors

Generando el fichero R. (0.79s)
Compilando el código del motor de depuración. (10.55s)
Compilando el código Java generado. (10.60s)
Convirtiendo byte code a dex optimizado. Error
Uncaught translation error: java.lang.IllegalArgumentException: already added: Landroid/support/v4/app/INotificationSideChannel;
Uncaught translation error: java.lang.IllegalArgumentException: already added: Landroid/support/v4/app/INotificationSideChannel$Stub;
Uncaught translation error: java.lang.IllegalArgumentException: already added: Landroid/support/v4/app/INotificationSideChannel$Stub$Proxy;
Uncaught translation error: java.lang.IllegalArgumentException: already added: Landroid/support/v4/os/IResultReceiver;
Uncaught translation error: java.lang.IllegalArgumentException: already added: Landroid/support/v4/os/IResultReceiver$Stub;
Uncaught translation error: java.lang.IllegalArgumentException: already added: Landroid/support/v4/os/IResultReceiver$Stub$Proxy;
Uncaught translation error: java.lang.IllegalArgumentException: already added: Landroid/support/v4/os/ResultReceiver;
Uncaught translation error: java.lang.IllegalArgumentException: already added: Landroid/support/v4/os/ResultReceiver$1;
Uncaught translation error: java.lang.IllegalArgumentException: already added: Landroid/support/v4/os/ResultReceiver$MyResultReceiver;
UNEXPECTED TOP-LEVEL EXCEPTION:
java.lang.RuntimeException: Translation has been interrupted
at com.android.dx.command.dexer.Main.processAllFiles(Main.java:692)
at com.android.dx.command.dexer.Main.runMonoDex(Main.java:315)
at com.android.dx.command.dexer.Main.runDx(Main.java:293)
at com.android.dx.command.dexer.Main.main(Main.java:249)
at com.android.dx.command.Main.main(Main.java:94)
Caused by: java.lang.InterruptedException: Too many errors
at com.android.dx.command.dexer.Main.processAllFiles(Main.java:684)
... 4 more
 

Alberto Michelis

Well-Known Member
Licensed User
Yes
Generando el fichero R. (0.69s)
Compilando el código del motor de depuración. (1.43s)
Compilando el código Java generado. (2.73s)
Convirtiendo byte code a dex optimizado. (33.59s)
Empaquetando ficheros. (2.94s)
Copiando los recursos de librerias (0.16s)
Found 21 resource files.
Firmando ficheros de paquete (clave privada) (2.47s)
ZipAlign file. (0.08s)

Compile the original app ok
Just adding the FirebaseAdMob lib to the project, without any reference to it or any change in the manifest, I compile and get the errors shown in my previous post.
Dont know what to look for...
Landroid/support/v4/ does not exists...
How can I fix it?
 
Last edited:
Top