AppLovin / AppLovin-MAX-Unity-Plugin

110 stars 31 forks source link

Crash after update to 6.4.2 #355

Open jedai7 opened 1 month ago

jedai7 commented 1 month ago

MAX Plugin Version

6.4.2

Unity Version

2021.3.24

Device/Platform Info

iOs

Current Behavior

Crash after updating to 6.4.2 2024-04-09 18:20:06.585921+0300 CryptoTycoon[86767:39621903] AppLovinQualityService top: AppLovinQualityService Client Version: 7.2.0 2024-04-09 18:20:06.585965+0300 CryptoTycoon[86767:39621903] AppLovinQualityService top: AppLovinQualityService Device ID: 34BC732D-DFE4-42F2-BF73-0FD7CF4C5568 2024-04-09 18:20:06.845016+0300 CryptoTycoon[86767:39621903] [general] Error loading /var/containers/Bundle/Application/29A2C43C-EE60-43F9-8E74-AC47A71311C2/CryptoTycoon.app/Frameworks/UnityFramework.framework/UnityFramework (139): dlopen(/var/containers/Bundle/Application/29A2C43C-EE60-43F9-8E74-AC47A71311C2/CryptoTycoon.app/Frameworks/UnityFramework.framework/UnityFramework, 0x0109): Library not loaded: @rpath/AppLovinSDK.framework/AppLovinSDK Referenced from: <F17D78E2-1008-33DB-ABA4-2E0AA957695A> /private/var/containers/Bundle/Application/29A2C43C-EE60-43F9-8E74-AC47A71311C2/CryptoTycoon.app/Frameworks/UnityFramework.framework/UnityFramework Reason: tried: '/usr/lib/swift/AppLovinSDK.framework/AppLovinSDK' (errno=2, not in dyld cache), '/private/preboot/Cryptexes/OS/usr/lib/swift/AppLovinSDK.framework/AppLovinSDK' (errno=2), '/private/var/containers/Bundle/Application/29A2C43C-EE60-43F9-8E74-AC47A71311C2/CryptoTycoon.app/Frameworks/AppLovinSDK.framework/AppLovinSDK' (errno=2), '/private/var/containers/Bundle/Application/29A2C43C-EE60-43F9-8E74-AC47A71311C2/CryptoTycoon.app/Frameworks/UnityFramework.framework/Frameworks/AppLovinSDK.framework/AppLovinSDK' (errno=2), '/private/var/containers/Bundle/Application/Frameworks/AppLovinSDK.framework/AppLovinSDK' (errno=2), '/usr/lib/swift/AppLovinSDK.framework/AppLovinSDK' (errno=2, not in dyld cache), '/private/preboot/Cryptexes/OS/usr/lib/swift/AppLovinSDK.framework/AppLovinSDK' (errno=2), '/private/var/containers/Bundle/Application/29A2C43C-EE60-43F9-8E74-AC47A71311C2/CryptoTycoon.app/Frameworks/AppLovinSDK.framework/AppLovinSDK' (errno=2), '/private/var/containers/Bundle/Application/29A2C43C-EE60-43F9-8E74-AC47A71311C2/CryptoTycoon.app/Frameworks/UnityFramework.framework/Frameworks/AppLovinSDK.framework/AppLovinSDK' (errno=2), '/private/var/containers/Bundle/Application/Frameworks/AppLovinSDK.framework/AppLovinSDK' (errno=2), '/private/var/containers/Bundle/Application/29A2C43C-EE60-43F9-8E74-AC47A71311C2/CryptoTycoon.app/Frameworks/AppLovinSDK.framework/AppLovinSDK' (errno=2), '/private/preboot/Cryptexes/OS@rpath/AppLovinSDK.framework/AppLovinSDK' (errno=2), '/usr/lib/swift/AppLovinSDK.framework/AppLovinSDK' (errno=2, not in dyld cache), '/private/preboot/Cryptexes/OS/usr/lib/swift/AppLovinSDK.framework/AppLovinSDK' (errno=2), '/private/var/containers/Bundle/Application/29A2C43C-EE60-43F9-8E74-AC47A71311C2/CryptoTycoon.app/Frameworks/AppLovinSDK.framework/AppLovinSDK' (errno=2), '/private/var/containers/Bundle/Application/29A2C43C-EE60-43F9-8E74-AC47A71311C2/CryptoTycoon.app/Frameworks/UnityFramework.framework/Frameworks/AppLovinSDK.framework/AppLovinSDK' (errno=2), '/private/var/containers/Bundle/Application/Frameworks/AppLovinSDK.framework/AppLovinSDK' (errno=2), '/usr/lib/swift/AppLovinSDK.framework/AppLovinSDK' (errno=2, not in dyld cache), '/private/preboot/Cryptexes/OS/usr/lib/swift/AppLovinSDK.framework/AppLovinSDK' (errno=2), '/private/var/containers/Bundle/Application/29A2C43C-EE60-43F9-8E74-AC47A71311C2/CryptoTycoon.app/Frameworks/AppLovinSDK.framework/AppLovinSDK' (errno=2), '/private/var/containers/Bundle/Application/29A2C43C-EE60-43F9-8E74-AC47A71311C2/CryptoTycoon.app/Frameworks/UnityFramework.framework/Frameworks/AppLovinSDK.framework/AppLovinSDK' (errno=2), '/private/var/containers/Bundle/Application/Frameworks/AppLovinSDK.framework/AppLovinSDK' (errno=2), '/private/var/containers/Bundle/Application/29A2C43C-EE60-43F9-8E74-AC47A71311C2/CryptoTycoon.app/Frameworks/AppLovinSDK.framework/AppLovinSDK' (errno=2) 2024-04-09 18:20:06.971271+0300 CryptoTycoon[86767:39621903] [general] Error loading /var/containers/Bundle/Application/29A2C43C-EE60-43F9-8E74-AC47A71311C2/CryptoTycoon.app/Frameworks/UnityFramework.framework/UnityFramework (139): dlopen(/var/containers/Bundle/Application/29A2C43C-EE60-43F9-8E74-AC47A71311C2/CryptoTycoon.app/Frameworks/UnityFramework.framework/UnityFramework, 0x0109): Library not loaded: @rpath/AppLovinSDK.framework/AppLovinSDK Referenced from: <F17D78E2-1008-33DB-ABA4-2E0AA957695A> /private/var/containers/Bundle/Application/29A2C43C-EE60-43F9-8E74-AC47A71311C2/CryptoTycoon.app/Frameworks/UnityFramework.framework/UnityFramework Reason: tried: '/usr/lib/swift/AppLovinSDK.framework/AppLovinSDK' (errno=2, not in dyld cache), '/private/preboot/Cryptexes/OS/usr/lib/swift/AppLovinSDK.framework/AppLovinSDK' (errno=2), '/private/var/containers/Bundle/Application/29A2C43C-EE60-43F9-8E74-AC47A71311C2/CryptoTycoon.app/Frameworks/AppLovinSDK.framework/AppLovinSDK' (errno=2), '/private/var/containers/Bundle/Application/29A2C43C-EE60-43F9-8E74-AC47A71311C2/CryptoTycoon.app/Frameworks/UnityFramework.framework/Frameworks/AppLovinSDK.framework/AppLovinSDK' (errno=2), '/private/var/containers/Bundle/Application/Frameworks/AppLovinSDK.framework/AppLovinSDK' (errno=2), '/usr/lib/swift/AppLovinSDK.framework/AppLovinSDK' (errno=2, not in dyld cache), '/private/preboot/Cryptexes/OS/usr/lib/swift/AppLovinSDK.framework/AppLovinSDK' (errno=2), '/private/var/containers/Bundle/Application/29A2C43C-EE60-43F9-8E74-AC47A71311C2/CryptoTycoon.app/Frameworks/AppLovinSDK.framework/AppLovinSDK' (errno=2), '/private/var/containers/Bundle/Application/29A2C43C-EE60-43F9-8E74-AC47A71311C2/CryptoTycoon.app/Frameworks/UnityFramework.framework/Frameworks/AppLovinSDK.framework/AppLovinSDK' (errno=2), '/private/var/containers/Bundle/Application/Frameworks/AppLovinSDK.framework/AppLovinSDK' (errno=2), '/private/var/containers/Bundle/Application/29A2C43C-EE60-43F9-8E74-AC47A71311C2/CryptoTycoon.app/Frameworks/AppLovinSDK.framework/AppLovinSDK' (errno=2), '/private/preboot/Cryptexes/OS@rpath/AppLovinSDK.framework/AppLovinSDK' (errno=2), '/usr/lib/swift/AppLovinSDK.framework/AppLovinSDK' (errno=2, not in dyld cache), '/private/preboot/Cryptexes/OS/usr/lib/swift/AppLovinSDK.framework/AppLovinSDK' (errno=2), '/private/var/containers/Bundle/Application/29A2C43C-EE60-43F9-8E74-AC47A71311C2/CryptoTycoon.app/Frameworks/AppLovinSDK.framework/AppLovinSDK' (errno=2), '/private/var/containers/Bundle/Application/29A2C43C-EE60-43F9-8E74-AC47A71311C2/CryptoTycoon.app/Frameworks/UnityFramework.framework/Frameworks/AppLovinSDK.framework/AppLovinSDK' (errno=2), '/private/var/containers/Bundle/Application/Frameworks/AppLovinSDK.framework/AppLovinSDK' (errno=2), '/usr/lib/swift/AppLovinSDK.framework/AppLovinSDK' (errno=2, not in dyld cache), '/private/preboot/Cryptexes/OS/usr/lib/swift/AppLovinSDK.framework/AppLovinSDK' (errno=2), '/private/var/containers/Bundle/Application/29A2C43C-EE60-43F9-8E74-AC47A71311C2/CryptoTycoon.app/Frameworks/AppLovinSDK.framework/AppLovinSDK' (errno=2), '/private/var/containers/Bundle/Application/29A2C43C-EE60-43F9-8E74-AC47A71311C2/CryptoTycoon.app/Frameworks/UnityFramework.framework/Frameworks/AppLovinSDK.framework/AppLovinSDK' (errno=2), '/private/var/containers/Bundle/Application/Frameworks/AppLovinSDK.framework/AppLovinSDK' (errno=2), '/private/var/containers/Bundle/Application/29A2C43C-EE60-43F9-8E74-AC47A71311C2/CryptoTycoon.app/Frameworks/AppLovinSDK.framework/AppLovinSDK' (errno=2)

Expected Behavior

No response

How to Reproduce

Update to 6.4.2

Additional Info

No response

santoshbagadi commented 1 month ago

Hi @jedai7 , could you please share the Podfile for the build. Do you mind making sure that these External Dependency Manager settings are being set correctly: https://dash.applovin.com/documentation/mediation/unity/getting-started/integration#external-dependency-manager

jedai7 commented 1 month ago

Hi @santoshbagadi My settings have been like this for almost 5 years, such settings are needed to combine different third-party plugins. And for the last 5 years everything has been fine telegram-cloud-photo-size-2-5237901922906790615-x but when I use your recommended settings my build breaks telegram-cloud-photo-size-2-5237901922906790618-y iOS framework addition failed due to a CocoaPods installation failure. This will will likely result in an non-functional Xcode project.

After the failure, "pod repo update" was executed and succeeded. "pod install" was then attempted again, and still failed. This may be due to a broken CocoaPods installation. See: https://guides.cocoapods.org/using/troubleshooting.html for potential solutions.

pod install output:

[!] The following Swift pods cannot yet be integrated as static libraries:

The Swift pod FirebaseCoreInternal depends upon GoogleUtilities, which does not define modules. To opt into those targets generating module maps (which is necessary to import them from Swift when building as static libraries), you may set use_modular_headers! globally in your Podfile, or specify :modular_headers => true for particular dependencies.

The Swift pod FirebaseRemoteConfig depends upon FirebaseABTesting, FirebaseCore, FirebaseInstallations, and GoogleUtilities, which do not define modules. To opt into those targets generating module maps (which is necessary to import them from Swift when building as static libraries), you may set use_modular_headers! globally in your Podfile, or specify :modular_headers => true for particular dependencies.

The Swift pod FirebaseSessions depends upon FirebaseCore, FirebaseCoreExtension, FirebaseInstallations, GoogleDataTransport, GoogleUtilities, and nanopb, which do not define modules. To opt into those targets generating module maps (which is necessary to import them from Swift when building as static libraries), you may set use_modular_headers! globally in your Podfile, or specify :modular_headers => true for particular dependencies.

santoshbagadi commented 1 month ago

@jedai7 thank you for including all the testing details. We are seeing that CocoaPods has slight variations in how it links frameworks to each target in a multi target project. We are seeing that CocoaPods sometimes links the pods to the Unity-iPhone target, but sometimes it doesn't.

A temporary fix would be to keep the old External Dependency Manager (EDM) settings and embed the AppLovinSdk to the Unity-iPhone target.

We are working on a way to detect the different ways CocoaPods links the targets and automating the embedding process.

jedai7 commented 1 month ago

@santoshbagadi I see that your SDK is using External Dependency Manager version 1.2.176, and the build is not working. I also tried using External Dependency Manager version 1.2.169, and the build is still not working. Which version do I need?

santoshbagadi commented 1 month ago

The issue is not specific to an External Dependency Manager version. We think it is CocoaPods version related

jedai7 commented 1 month ago

Could you please ping me when you figure out the issue? It's critical as it's blocking our new release with the new Apple privacy requirements

jedai7 commented 1 month ago

@santoshbagadi I think I've found the root cause. Updating CocoaPods or EDM don't fix the situation, as the issue elsewhere. In the script "AppLovinPostProcessiOS," method "ContainsUnityIphoneTargetInPodfile," you're checking for the presence of "target 'Unity-iPhone' do" in the Podfile, and consequently, the AppLovinSDK.xcframework isn't being added to the Unity-iPhone target.

santoshbagadi commented 1 month ago

@jedai7 yes, that logic is intentional since older versions of CocoaPods (older than v1.12.0) automatically link the libraries to the main target as well if Unity-iPhone target is present in the Podfile. We are working on detecting this in a more dynamic way to embed the libraries only when CocoaPods doesn't link them. I'll update here once we have a solution and a new release is ready.

agrobost commented 1 month ago

Hello, our application fails to build if 'Add use_frameworks! to Podfile' and 'Always add the main target to Podfile' are unchecked, specifically due to Facebook SDK dependencies..

If these options are checked, the build succeeds, but the application crashes on startup only since Max's update. Could you provide guidance or a fix for this issue?

jedai7 commented 1 month ago

I fixed it by next step

  1. downgrade EDM to 1.2.167. Settings image

2.AppLovinPostProcessiOS fix method ContainsUnityIphoneTargetInPodfile image

  1. Fix list DynamicLibrariesToEmbed image
JonathanLiuApp commented 1 month ago

We've released a fix for this in the latest version of our plugin (6.4.3).

jedai7 commented 1 month ago

@JonathanLiuApp I have two projects: With Facebook SDK. Without Facebook SDK.

After updating to version 6.4.3, I don't have any issues with the project without Facebook SDK. However, I encounter build issues with the other one. If I include the Facebook SDK, I'm unable to build. Here are my logs:"

[11:52:14]: ▸ ❌ error: Multiple commands produce '/Users/arturgrigorjan/Library/Developer/Xcode/DerivedData/Unity-iPhone-hknifzheycduncfrcrundrjnsxkq/Build/Intermediates.noindex/ArchiveIntermediates/Unity-iPhone/InstallationBuildProductsLocation/Applications/TemplateAAA.app/Frameworks/FBSDKGamingServicesKit.framework' [11:52:14]: ▸ ❌ error: Multiple commands produce '/Users/arturgrigorjan/Library/Developer/Xcode/DerivedData/Unity-iPhone-hknifzheycduncfrcrundrjnsxkq/Build/Intermediates.noindex/ArchiveIntermediates/Unity-iPhone/InstallationBuildProductsLocation/Applications/TemplateAAA.app/Frameworks/FBSDKCoreKit_Basics.framework' [11:52:14]: ▸ ❌ error: Multiple commands produce '/Users/arturgrigorjan/Library/Developer/Xcode/DerivedData/Unity-iPhone-hknifzheycduncfrcrundrjnsxkq/Build/Intermediates.noindex/ArchiveIntermediates/Unity-iPhone/InstallationBuildProductsLocation/Applications/TemplateAAA.app/Frameworks/FBSDKLoginKit.framework' [11:52:14]: ▸ ❌ error: Multiple commands produce '/Users/arturgrigorjan/Library/Developer/Xcode/DerivedData/Unity-iPhone-hknifzheycduncfrcrundrjnsxkq/Build/Intermediates.noindex/ArchiveIntermediates/Unity-iPhone/InstallationBuildProductsLocation/Applications/TemplateAAA.app/Frameworks/FBSDKShareKit.framework' [11:52:14]: ▸ ❌ error: Multiple commands produce '/Users/arturgrigorjan/Library/Developer/Xcode/DerivedData/Unity-iPhone-hknifzheycduncfrcrundrjnsxkq/Build/Intermediates.noindex/ArchiveIntermediates/Unity-iPhone/InstallationBuildProductsLocation/Applications/TemplateAAA.app/Frameworks/FBSDKCoreKit.framework' [11:52:14]: ▸ ❌ error: Multiple commands produce '/Users/arturgrigorjan/Library/Developer/Xcode/DerivedData/Unity-iPhone-hknifzheycduncfrcrundrjnsxkq/Build/Intermediates.noindex/ArchiveIntermediates/Unity-iPhone/InstallationBuildProductsLocation/Applications/TemplateAAA.app/Frameworks/FBAEMKit.framework'

bearhugmo commented 1 month ago

I can confirm that I see the same issue on 6.4.3. The ticket should be reopened @santoshbagadi @JonathanLiuApp

@JonathanLiuApp I have two projects: With Facebook SDK. Without Facebook SDK.

After updating to version 6.4.3, I don't have any issues with the project without Facebook SDK. However, I encounter build issues with the other one. If I include the Facebook SDK, I'm unable to build. Here are my logs:"

[11:52:14]: ▸ ❌ error: Multiple commands produce '/Users/arturgrigorjan/Library/Developer/Xcode/DerivedData/Unity-iPhone-hknifzheycduncfrcrundrjnsxkq/Build/Intermediates.noindex/ArchiveIntermediates/Unity-iPhone/InstallationBuildProductsLocation/Applications/TemplateAAA.app/Frameworks/FBSDKGamingServicesKit.framework' [11:52:14]: ▸ ❌ error: Multiple commands produce '/Users/arturgrigorjan/Library/Developer/Xcode/DerivedData/Unity-iPhone-hknifzheycduncfrcrundrjnsxkq/Build/Intermediates.noindex/ArchiveIntermediates/Unity-iPhone/InstallationBuildProductsLocation/Applications/TemplateAAA.app/Frameworks/FBSDKCoreKit_Basics.framework' [11:52:14]: ▸ ❌ error: Multiple commands produce '/Users/arturgrigorjan/Library/Developer/Xcode/DerivedData/Unity-iPhone-hknifzheycduncfrcrundrjnsxkq/Build/Intermediates.noindex/ArchiveIntermediates/Unity-iPhone/InstallationBuildProductsLocation/Applications/TemplateAAA.app/Frameworks/FBSDKLoginKit.framework' [11:52:14]: ▸ ❌ error: Multiple commands produce '/Users/arturgrigorjan/Library/Developer/Xcode/DerivedData/Unity-iPhone-hknifzheycduncfrcrundrjnsxkq/Build/Intermediates.noindex/ArchiveIntermediates/Unity-iPhone/InstallationBuildProductsLocation/Applications/TemplateAAA.app/Frameworks/FBSDKShareKit.framework' [11:52:14]: ▸ ❌ error: Multiple commands produce '/Users/arturgrigorjan/Library/Developer/Xcode/DerivedData/Unity-iPhone-hknifzheycduncfrcrundrjnsxkq/Build/Intermediates.noindex/ArchiveIntermediates/Unity-iPhone/InstallationBuildProductsLocation/Applications/TemplateAAA.app/Frameworks/FBSDKCoreKit.framework' [11:52:14]: ▸ ❌ error: Multiple commands produce '/Users/arturgrigorjan/Library/Developer/Xcode/DerivedData/Unity-iPhone-hknifzheycduncfrcrundrjnsxkq/Build/Intermediates.noindex/ArchiveIntermediates/Unity-iPhone/InstallationBuildProductsLocation/Applications/TemplateAAA.app/Frameworks/FBAEMKit.framework'

I see the same issue.

It can be avoided by checking to see if the file is already embedded first.

            if (ShouldEmbedDynamicLibraries(buildPath))
            {
                foreach (var dynamicLibraryPath in dynamicLibraryPathsPresentInProject)
                {
                    if (!project.ContainsFileByProjectPath(dynamicLibraryPath))
                    {
                        var fileGuid = project.AddFile(dynamicLibraryPath, dynamicLibraryPath);
                        project.AddFileToEmbedFrameworks(targetGuid, fileGuid);
                    }
                }
            }
agrobost commented 1 month ago

@JonathanLiuApp I have two projects: With Facebook SDK. Without Facebook SDK.

After updating to version 6.4.3, I don't have any issues with the project without Facebook SDK. However, I encounter build issues with the other one. If I include the Facebook SDK, I'm unable to build. Here are my logs:"

[11:52:14]: ▸ ❌ error: Multiple commands produce '/Users/arturgrigorjan/Library/Developer/Xcode/DerivedData/Unity-iPhone-hknifzheycduncfrcrundrjnsxkq/Build/Intermediates.noindex/ArchiveIntermediates/Unity-iPhone/InstallationBuildProductsLocation/Applications/TemplateAAA.app/Frameworks/FBSDKGamingServicesKit.framework' [11:52:14]: ▸ ❌ error: Multiple commands produce '/Users/arturgrigorjan/Library/Developer/Xcode/DerivedData/Unity-iPhone-hknifzheycduncfrcrundrjnsxkq/Build/Intermediates.noindex/ArchiveIntermediates/Unity-iPhone/InstallationBuildProductsLocation/Applications/TemplateAAA.app/Frameworks/FBSDKCoreKit_Basics.framework' [11:52:14]: ▸ ❌ error: Multiple commands produce '/Users/arturgrigorjan/Library/Developer/Xcode/DerivedData/Unity-iPhone-hknifzheycduncfrcrundrjnsxkq/Build/Intermediates.noindex/ArchiveIntermediates/Unity-iPhone/InstallationBuildProductsLocation/Applications/TemplateAAA.app/Frameworks/FBSDKLoginKit.framework' [11:52:14]: ▸ ❌ error: Multiple commands produce '/Users/arturgrigorjan/Library/Developer/Xcode/DerivedData/Unity-iPhone-hknifzheycduncfrcrundrjnsxkq/Build/Intermediates.noindex/ArchiveIntermediates/Unity-iPhone/InstallationBuildProductsLocation/Applications/TemplateAAA.app/Frameworks/FBSDKShareKit.framework' [11:52:14]: ▸ ❌ error: Multiple commands produce '/Users/arturgrigorjan/Library/Developer/Xcode/DerivedData/Unity-iPhone-hknifzheycduncfrcrundrjnsxkq/Build/Intermediates.noindex/ArchiveIntermediates/Unity-iPhone/InstallationBuildProductsLocation/Applications/TemplateAAA.app/Frameworks/FBSDKCoreKit.framework' [11:52:14]: ▸ ❌ error: Multiple commands produce '/Users/arturgrigorjan/Library/Developer/Xcode/DerivedData/Unity-iPhone-hknifzheycduncfrcrundrjnsxkq/Build/Intermediates.noindex/ArchiveIntermediates/Unity-iPhone/InstallationBuildProductsLocation/Applications/TemplateAAA.app/Frameworks/FBAEMKit.framework'

I encounter the same bug; to resolve it, I remove all references of 'addToAllTargets="true"' in the 'facebook dependencies.xml' file:

<?xml version="1.0" encoding="utf-8"?>
<dependencies>
    <androidPackages>
        <androidPackage spec="com.parse.bolts:bolts-android:1.4.0" />
        <androidPackage spec="com.facebook.android:facebook-core:[16.0.1,17)" />
        <androidPackage spec="com.facebook.android:facebook-applinks:[16.0.1,17)" />
        <androidPackage spec="com.facebook.android:facebook-login:[16.0.1,17)" />
        <androidPackage spec="com.facebook.android:facebook-share:[16.0.1,17)" />
        <androidPackage spec="com.facebook.android:facebook-gamingservices:[16.0.1,17)" />
    </androidPackages>
    <iosPods>
        <iosPod name="FBSDKCoreKit_Basics" version="~> 16.0.1" addToAllTargets="true" />
        <iosPod name="FBSDKCoreKit" version="~> 16.0.1" addToAllTargets="true" />
        <iosPod name="FBSDKLoginKit" version="~> 16.0.1" addToAllTargets="true" />
        <iosPod name="FBSDKShareKit" version="~> 16.0.1" addToAllTargets="true" />
        <iosPod name="FBSDKGamingServicesKit" version="~> 16.0.1" addToAllTargets="true" />
    </iosPods>
</dependencies>
santoshbagadi commented 1 month ago

@bearhugmo and @agrobost thank you for suggesting the fixes. I've tested with the latest Facebook SDK before making this push and noticed that Facebook doesn't automatically add to all targets. Which is why we added support for it.

We'll include a fix in the next release to only embed a library if not already added to the Unity-iPhone target.

jedai7 commented 1 month ago

@santoshbagadi Can you also urge Facebook to update the Audience Network? We're encountering a conflict between the Audience Network and the Facebook adapter within Applovin. [14:13:00]: ▸ [!] CocoaPods could not find compatible versions for pod "FBAudienceNetwork": [14:13:00]: ▸ In Podfile: [14:13:00]: ▸ AppLovinMediationFacebookAdapter (= 6.12.0.2) was resolved to 6.12.0.2, which depends on [14:13:00]: ▸ FBAudienceNetwork (= 6.12.0) [14:13:00]: ▸ FBAudienceNetwork (~> 6.15.0)

gagbaghdas commented 1 month ago

Manually adding AppLovinSDK.xcframework to Unity-iPhone works.

cometa93 commented 1 month ago

Hey, I've just updated to the 6.4.3 version and it still fails to run the game

santoshbagadi commented 1 month ago

@cometa93 do you mind sharing the External Dependency Manager settings for the project and the Podfile of the exported project.

cometa93 commented 1 month ago
source 'https://cdn.cocoapods.org/'

platform :ios, '12.0'

target 'UnityFramework' do
  pod 'AppLovinMediationFacebookAdapter', '6.15.0.0'
  pod 'AppLovinMediationGoogleAdapter', '11.3.0.0'
  pod 'AppLovinMediationUnityAdsAdapter', '4.10.0.0'
  pod 'AppLovinSDK', '12.4.1'
  pod 'Firebase/Analytics', '10.20.0'
  pod 'Firebase/Auth', '10.20.0'
  pod 'Firebase/Core', '10.20.0'
  pod 'Firebase/Crashlytics', '10.20.0'
  pod 'Firebase/Firestore', '10.20.0'
  pod 'Firebase/Messaging', '10.20.0'
  pod 'Firebase/RemoteConfig', '10.20.0'
  pod 'FirebaseFirestoreInternal', '10.22.0'
  pod 'GoogleUserMessagingPlatform', '2.1.0'
end
target 'Unity-iPhone' do
end
use_frameworks! :linkage => :static

image

@santoshbagadi I hope that helps

santoshbagadi commented 1 month ago

@cometa93 thank you for sharing it. The settings looks correct, so, you should not be able to run into this crash after updating to 6.4.3 of our plugin.

What is the exact crash stacktrace you are seeing? Do you mind checking that the AppLovinSDK.xcframework is being added as a embedded framework to Unity-iPhone target?

cometa93 commented 1 month ago

Give me 10 min, will clear build, remove app from testing phone and build clean everything, xCode is caching too many things, I see it's embedded

cometa93 commented 1 month ago

I confirm, it's working. The problem was:

I've been building the version with same buildNumber, on the same project, xCode didn't reinstall the app instead was running it again. I'm sorry for my mistake. All good!

huangzhiquan497 commented 1 week ago

why 6.4.4 it still fails to run the game,and Manually adding AppLovinSDK.xcframework to Unity-iPhone works.