I’m still trying to update the FB extension and prepared a branch just to illustrate the issue I’m stuck with.
Here is a dev branch in forked repo from original defold facebook-extension: https://github.com/MaratGilyazov/extension-facebook/tree/update_6.3.0/android
I did just few changes: https://github.com/MaratGilyazov/extension-facebook/commit/997d9e26908cfaef90cfc6baffa08b21683fcd68
First of all - switched dependencies to a new 6.3.0 SDK (now there is only one dependency required). If keep just this chane - extension itself can be build without any issues.
But in a real project I also need Admob, so I’ve also added a dependency for Admob just to illustrate the conflict - now it fails with the message, I’ve mentioned in previous messages:
Attribute application@appComponentFactory value=(androidx.core.app.CoreComponentFactory) from AndroidManifest.xml:24:18-86 is also present at AndroidManifest.xml:22:18-91 value=(android.support.v4.app.CoreComponentFactory).
Thats the main issue I can’t solve by my own
- I see there is a dependency for android.support.v4.app.FragmentActivity - I believe as long as FB switched to AndroidX there should be no refs to “old”
When I run “Migrate to AndroidX” command from Android Studio it changes this import directive to androidx.core.app.FragmentActivity + asks me to add gradle.properties file with lines mentioned above:
But when I try to build from such state, it fails with such error:
And anyway, this class seems to be not used here at all, so I’ve simply commented it out, but this thing is minor, as build fails on step (2).
Any ideas what I’m doing wrong and how to fix the issue?
BTW, if I use only dependency to Admob itself, without facebook, it builds normally (in my ironsource extension, for ex), so build fails only in combination of FB extension and other up-to-date plugins like Admob or Firebase