Comments (30)
Good to know, will avoid updating any ad adapters for now :)
from facebook-sdk-for-unity.
On my side I get NULL Ref inside unitys methods at this line string mainTarget = pbxProject.GetUnityMainTargetGuid();
Trying to find out another method of getting the target name...
Sorry, mistake on my part - you should call pbxProject.ReadFromFile(projectPath); before trying to resolve targets.
Updated the original code
from facebook-sdk-for-unity.
@NudeNULL Just use version 14 of facebook SDK, why do you want to update it ? this version is broken and no one from the facebook team cares
About the Unity version, I had a crash on unity 2021.3 , it's not caused by unity
from facebook-sdk-for-unity.
Finally got a working build.
The certificates issue was solved by removing the build step in our Jenkins job made by using Xcode plugin, and wrote a custom shell script (after a day of fighting with chatgpt), that builds ad hoc ipa file.
The Facebook crash was fixed by downgrading to 14.1 version.
from facebook-sdk-for-unity.
from facebook-sdk-for-unity.
dead plugin
from facebook-sdk-for-unity.
dead plugin
What do you mean? I describe the solution in the thread I posted
from facebook-sdk-for-unity.
dead plugin
What do you mean? I describe the solution in the thread I posted
unchecking that doesn't work in our projects , Firebase and some of google plugins will throw build errors
from facebook-sdk-for-unity.
unchecking that doesn't work in our projects , Firebase and some of google plugins will throw build errors
We also use Firebase and google plugins. What about all the other parts I mentioned, what's your cocoapods version and xcode version?
from facebook-sdk-for-unity.
unchecking that doesn't work in our projects , Firebase and some of google plugins will throw build errors
We also use Firebase and google plugins. What about all the other parts I mentioned, what's your cocoapods version and xcode version?
cocoapods is 1.12.1 and xcode 14.3.1
from facebook-sdk-for-unity.
unchecking that doesn't work in our projects , Firebase and some of google plugins will throw build errors
We also use Firebase and google plugins. What about all the other parts I mentioned, what's your cocoapods version and xcode version?
Error is :
Undefined symbols for architecture arm64:
"_GADAdLoaderAdTypeNative", referenced from:
___73-[ALGoogleMediationAdapter loadAdViewAdForParameters:adFormat:andNotify:]_block_invoke in libGoogleAdapter.a(ALGoogleMediationAdapter.o)
___64-[ALGoogleMediationAdapter loadNativeAdForParameters:andNotify:]_block_invoke in libGoogleAdapter.a(ALGoogleMediationAdapter.o)
"_GADAdSizeBanner", referenced from:
-[ALGoogleMediationAdapter adSizeFromAdFormat:isAdaptiveBanner:parameters:] in libGoogleAdapter.a(ALGoogleMediationAdapter.o)
"_GADAdSizeLeaderboard", referenced from:
-[ALGoogleMediationAdapter adSizeFromAdFormat:isAdaptiveBanner:parameters:] in libGoogleAdapter.a(ALGoogleMediationAdapter.o)
"_GADAdSizeMediumRectangle", referenced from:
-[ALGoogleMediationAdapter adSizeFromAdFormat:isAdaptiveBanner:parameters:] in libGoogleAdapter.a(ALGoogleMediationAdapter.o)
"_GADCurrentOrientationAnchoredAdaptiveBannerAdSizeWithWidth", referenced from:
___75-[ALGoogleMediationAdapter adSizeFromAdFormat:isAdaptiveBanner:parameters:]_block_invoke in libGoogleAdapter.a(ALGoogleMediationAdapter.o)
+[ALGoogleMediationAdapter currentOrientationAchoredAdaptiveBannerSizeWithWidth:] in libGoogleAdapter.a(ALGoogleMediationAdapter.o)
"_GADGetStringFromVersionNumber", referenced from:
-[ALGoogleMediationAdapter SDKVersion] in libGoogleAdapter.a(ALGoogleMediationAdapter.o)
"_OBJC_CLASS_$_GADAdLoader", referenced from:
objc-class-ref in libGoogleAdapter.a(ALGoogleMediationAdapter.o)
"_OBJC_CLASS_$_GADAppOpenAd", referenced from:
objc-class-ref in libGoogleAdapter.a(ALGoogleMediationAdapter.o)
"_OBJC_CLASS_$_GADBannerView", referenced from:
objc-class-ref in libGoogleAdapter.a(ALGoogleMediationAdapter.o)
"_OBJC_CLASS_$_GADExtras", referenced from:
objc-class-ref in libGoogleAdapter.a(ALGoogleMediationAdapter.o)
(maybe you meant: _OBJC_CLASS_$_GADExtrasBridge)
"_OBJC_CLASS_$_GADInterstitialAd", referenced from:
objc-class-ref in libGoogleAdapter.a(ALGoogleMediationAdapter.o)
(maybe you meant: _OBJC_CLASS_$_GADInterstitialAdBridgeV8)
"_OBJC_CLASS_$_GADMediaView", referenced from:
objc-class-ref in libGoogleAdapter.a(ALGoogleNativeAdDelegate.o)
objc-class-ref in libGoogleAdapter.a(ALGoogleNativeAd.o)
objc-class-ref in libGoogleAdapter.a(ALGoogleNativeAdViewDelegate.o)
"_OBJC_CLASS_$_GADMobileAds", referenced from:
objc-class-ref in libGoogleAdapter.a(ALGoogleMediationAdapter.o)
(maybe you meant: _OBJC_CLASS_$_GADMobileAdsBridge)
"_OBJC_CLASS_$_GADNativeAdImageAdLoaderOptions", referenced from:
objc-class-ref in libGoogleAdapter.a(ALGoogleMediationAdapter.o)
"_OBJC_CLASS_$_GADNativeAdView", referenced from:
objc-class-ref in libGoogleAdapter.a(ALGoogleNativeAd.o)
objc-class-ref in libGoogleAdapter.a(ALGoogleNativeAdViewDelegate.o)
"_OBJC_CLASS_$_GADNativeAdViewAdOptions", referenced from:
objc-class-ref in libGoogleAdapter.a(ALGoogleMediationAdapter.o)
"_OBJC_CLASS_$_GADQueryInfo", referenced from:
objc-class-ref in libGoogleAdapter.a(ALGoogleMediationAdapter.o)
(maybe you meant: _OBJC_CLASS_$_GADQueryInfoBridge)
"_OBJC_CLASS_$_GADRequest", referenced from:
objc-class-ref in libGoogleAdapter.a(ALGoogleMediationAdapter.o)
(maybe you meant: _OBJC_CLASS_$_GADRequestBridge, _OBJC_CLASS_$_GADRequestBridgeV85 )
"_OBJC_CLASS_$_GADRewardedAd", referenced from:
objc-class-ref in libGoogleAdapter.a(ALGoogleMediationAdapter.o)
(maybe you meant: _OBJC_CLASS_$_GADRewardedAdBridge, _OBJC_CLASS_$_GADRewardedAdBridgeV8 )
"_OBJC_CLASS_$_GADRewardedInterstitialAd", referenced from:
objc-class-ref in libGoogleAdapter.a(ALGoogleMediationAdapter.o)
ld: symbol(s) not found for architecture arm64
clang: error: linker command failed with exit code 1 (use -v to see invocation)
from facebook-sdk-for-unity.
We also use AppLovin with GoogleMediation Adapter, did you try updating the adapter?
from facebook-sdk-for-unity.
Yes it's latest version , We actually managed to fix the crash issue with this solution #659 (comment)
but after that fix, we get this crash:
Frameworks/UnityFramework.framework/UnityFramework, 0x0109): Library not loaded: @rpath/IASDKCore.framework/IASDKCore
It seems that multiple packages are failing in recent versions of the xcode
Everything was fine in xcode 13 and facebook 14
from facebook-sdk-for-unity.
It also seems to be related to this one googleads/googleads-mobile-unity#2736
Because some people have the same error ( googleads/googleads-mobile-unity#2736 (comment) ) it seems they fixed it 5days ago but for me still not working
from facebook-sdk-for-unity.
Sadistic plugin, last week I tested all combinations of external dependency manager and all other settings possible and none worked!
I finally fixed it by downgrading Facebook SDK from 16.0.1 to 14.1.1 !
from facebook-sdk-for-unity.
We've the same issue after upgrading Facebook from 14 to 16, but it our case it cannot load DTBiOSSDK
.
from facebook-sdk-for-unity.
I could fix this by adding the addToAllTargets parameter in dependecies.xml
./Assets/FacebookSDK/Plugins/Editor/Dependencies.xml
<iosPods>
<iosPod name="FBSDKCoreKit_Basics" version="~> 15.1" addToAllTargets="true" />
<iosPod name="FBSDKCoreKit" version="~> 15.1" addToAllTargets="true"/>
<iosPod name="FBSDKLoginKit" version="~> 15.1" addToAllTargets="true"/>
<iosPod name="FBSDKShareKit" version="~> 15.1" addToAllTargets="true"/>
<iosPod name="FBSDKGamingServicesKit" version="~> 15.1" addToAllTargets="true"/>
</iosPods>
from facebook-sdk-for-unity.
In my case it was crashing because of the DisableBitcode script, since I deleted it the app started
from facebook-sdk-for-unity.
Actually no, it didn't help, no idea what happened then...But without Facebook SDK, even with 5-6 other SDKs everything works well, as always, gotta love the SDK team from facebook
from facebook-sdk-for-unity.
@uchar Feeling your pain m8! This is riddiculous that integrating simple stuff like an SDK takes days of work.
I think I got te working combination of setting to build iOS without crashing for FBSdk 16.0.1, Firebase 10.7.0 and AppLovinSDK 11.11.3:
Contrary to AppLovin docs, I checked all the toggles in the iOS Resolver Settings:
My Podfile looks like this (last part added during build callback):
source 'https://cdn.cocoapods.org/'
platform :ios, '12.0'
target 'UnityFramework' do
pod 'AppLovinMediationFacebookAdapter', '6.14.0.0'
pod 'AppLovinSDK', '11.11.3'
pod 'FBSDKCoreKit', '~> 16.0.1'
pod 'FBSDKCoreKit_Basics', '~> 16.0.1'
pod 'FBSDKGamingServicesKit', '~> 16.0.1'
pod 'FBSDKLoginKit', '~> 16.0.1'
pod 'FBSDKShareKit', '~> 16.0.1'
pod 'Firebase/Analytics', '10.7.0'
pod 'Firebase/Core', '10.7.0'
pod 'Firebase/Crashlytics', '10.7.0'
pod 'Firebase/Messaging', '10.7.0'
pod 'Protobuf'
pod 'UnityMediationSdk', '~> 1.0', :source => 'https://github.com/Unity-Technologies/unity-mediation-cocoapods-prod.git'
pod 'UnityMediationUnityAdapter', :source => 'https://github.com/Unity-Technologies/unity-mediation-cocoapods-prod.git'
end
target 'Unity-iPhone' do
pod 'FBSDKCoreKit', '~> 16.0.1'
pod 'FBSDKCoreKit_Basics', '~> 16.0.1'
pod 'FBSDKGamingServicesKit', '~> 16.0.1'
pod 'FBSDKLoginKit', '~> 16.0.1'
pod 'FBSDKShareKit', '~> 16.0.1'
end
use_frameworks! :linkage => :static
post_install do |installer|
installer.generated_projects.each do |project|
project.targets.each do |target|
target.build_configurations.each do |config|
config.build_settings['IPHONEOS_DEPLOYMENT_TARGET'] = '13.0'
end
end
end
end
Build Postprocess callback looks like this:
class DisableBytecodeSupport : IPostprocessBuildWithReport {
public int callbackOrder => 0;
public void OnPostprocessBuild(BuildReport report) {
if (report.summary.platform != BuildTarget.iOS)
return;
string projectPath = report.summary.outputPath + "/Unity-iPhone.xcodeproj/project.pbxproj";
var pbxProject = new PBXProject();
pbxProject.ReadFromFile(projectPath);
var mainTarget = pbxProject.GetUnityMainTargetGuid();
var testTarget = pbxProject.TargetGuidByName(PBXProject.GetUnityTestTargetName());
var unityFrameworkTarget = pbxProject.GetUnityFrameworkTargetGuid();
pbxProject.AddShellScriptBuildPhase(
mainTarget,
"Run Script",
"/bin/sh",
@"cd ""${CONFIGURATION_BUILD_DIR}/${UNLOCALIZED_RESOURCES_FOLDER_PATH}/Frameworks/UnityFramework.framework/""
if [[ -d ""Frameworks"" ]]; then
rm -fr Frameworks
fi
"
);
#region Disabling Bitcode on all targets
pbxProject.SetBuildProperty(mainTarget, "ENABLE_BITCODE", "NO");
//Unity Tests
pbxProject.SetBuildProperty(testTarget, "ENABLE_BITCODE", "NO");
//Unity Framework
pbxProject.SetBuildProperty(unityFrameworkTarget, "ENABLE_BITCODE", "NO");
pbxProject.SetBuildProperty(unityFrameworkTarget, "ALWAYS_EMBED_SWIFT_STANDARD_LIBRARIES", "YES");
#endregion
// add Google Plist
pbxProject.AddFileToBuild (pbxProject.GetUnityMainTargetGuid(), pbxProject.AddFile("GoogleService-Info.plist", "GoogleService-Info.plist"));
pbxProject.WriteToFile(projectPath);
}
}
I also have Dependencies.xml set up like in the comment above:
#694 (comment)
Hope this helps!
from facebook-sdk-for-unity.
On my side I get NULL Ref inside unitys methods at this line
string mainTarget = pbxProject.GetUnityMainTargetGuid();
Trying to find out another method of getting the target name...
from facebook-sdk-for-unity.
Thanks for the update @Aare- , but I can't get the resulting podfile to look like yours, the bottom part is missing, no errors in logs, will try to investigate that for now.
from facebook-sdk-for-unity.
this is my podfile with the latest script changes used
source 'https://cdn.cocoapods.org/'
platform :ios, '13.0'
target 'UnityFramework' do
pod 'AppLovinMediationAdColonyAdapter', '4.9.0.0.4'
pod 'AppLovinMediationByteDanceAdapter', '5.4.1.1.0'
pod 'AppLovinMediationFacebookAdapter', '6.14.0.0'
pod 'AppLovinMediationFyberAdapter', '8.2.4.0'
pod 'AppLovinMediationGoogleAdapter', '10.10.0.0'
pod 'AppLovinMediationGoogleAdManagerAdapter', '10.10.0.0'
pod 'AppLovinMediationInMobiAdapter', '10.5.8.1'
pod 'AppLovinMediationIronSourceAdapter', '7.5.0.0.0'
pod 'AppLovinMediationMintegralAdapter', '7.4.6.0.0'
pod 'AppLovinMediationMyTargetAdapter', '5.19.0.0'
pod 'AppLovinMediationSmaatoAdapter', '22.4.0.0'
pod 'AppLovinMediationUnityAdsAdapter', '4.9.0.0'
pod 'AppLovinMediationVungleAdapter', '7.1.0.0'
pod 'AppLovinMediationYandexAdapter', '6.0.0.0'
pod 'AppLovinSDK', '11.11.3'
pod 'AppsFlyer-AdRevenue', '6.9.1'
pod 'AppsFlyerFramework', '6.12.1'
pod 'FBAudienceNetwork', '6.14.0.0'
pod 'FBSDKCoreKit', '~> 15.1'
pod 'FBSDKCoreKit_Basics', '~> 15.1'
pod 'FBSDKGamingServicesKit', '~> 15.1'
pod 'FBSDKLoginKit', '~> 15.1'
pod 'FBSDKShareKit', '~> 15.1'
pod 'Firebase/Analytics', '10.7.0'
pod 'Firebase/Core', '10.7.0'
pod 'YandexMobileMetrica', '4.2.0'
end
target 'Unity-iPhone' do
pod 'FBSDKCoreKit', '~> 15.1'
pod 'FBSDKCoreKit_Basics', '~> 15.1'
pod 'FBSDKGamingServicesKit', '~> 15.1'
pod 'FBSDKLoginKit', '~> 15.1'
pod 'FBSDKShareKit', '~> 15.1'
end
use_frameworks! :linkage => :static
from facebook-sdk-for-unity.
Also I saw Facebook just released a newer version of SDK, even though the dependencies are still the same -> 16.0.1, I will try it anyway.
from facebook-sdk-for-unity.
No, it didn't help, will look into crash logs tomorrow
from facebook-sdk-for-unity.
Hey @Aare- , what version of Unity do you use?
from facebook-sdk-for-unity.
@NudeNULL I'm on 2021.3.23f
I'm not sure if the last part of the podfile is required, but you can always add it manually to the generated xcode project.
It should be added by the build post process script but depending on your other plugins it might get overwritten.
I also see you have a lot of other plugins added, it might be a good idea to add them one by one and check which one exactly is causing the problems.
from facebook-sdk-for-unity.
I am seeing a pattern where already two developers have their projects on 2021.3.xx and they dont have the crash, where mine project is on 2020 version, will try the update and write here the result
from facebook-sdk-for-unity.
@NudeNULL Just use version 14 of facebook SDK, why do you want to update it ? this version is broken and no one from the facebook team cares
About the Unity version, I had a crash on unity 2021.3 , it's not caused by unity
I am not sure what was the reason for the update, I tried so many things that I forgot about trying the downgrade for facebook SDK, will see what happens with newer version of unity and then will try.
Because after upgrading unity we now have an issue with certificates, have no idea what unity upgrade have to do with triggering an error that says that xcode can't find the certificate with private key for the team id, I am losing my mind and becoming an insane person, day by day, need some psychotherapy...
Thank you facebook sdk team for making me want to kill someone ....
from facebook-sdk-for-unity.
@NudeNULL Unrelated to this issue, but check out: https://docs.fastlane.tools/actions/match/
This solved my issues with certificates for good
from facebook-sdk-for-unity.
Related Issues (20)
- Events not shooting up in Events Manager, Unity FB SDK. HOT 3
- Unable to start activity ComponentInfo{com.companyname/com.facebook.unity.FBUnityLoginActivity}
- 16.0.1 FB SDK doesn't keep user logged in on subsequent sessions HOT 5
- "_valueToSum" parameter in the event manager is empty when upgraded to SDK v16.0.1 HOT 2
- FacebookSDK generates excessive permanent GC memory
- HideUnityDelegate not used on Android?
- InvalidCastException : Unable to cast object of type ‘EditorFacebook’ to type ‘AndroidFacebook’
- [Android] Auto-Logging Purchase Issue after upgrading to Play Billing Library 5 HOT 3
- DT_TOOLCHAIN_DIR cannot be used to evaluate LIBRARY_SEARCH_PATHS, use TOOLCHAIN_DIR instead HOT 4
- Feature Request: Remove BOM from info.plist
- Library Conflict In unity
- Fetching profile picture results in empty texture2d HOT 1
- Exception: Too many receivers, total of 1000 HOT 1
- AndroidJavaException: java.lang.NoSuchMethodError: no static method with name='setIsUnityInit'
- FBUnityLoginActivity crash int java.lang.Enum.ordinal()' HOT 2
- Feature Request: Support App Privacy Manifest HOT 24
- missing Microsoft Xbox's build targets (using in 2020.3.x and higher) HOT 1
- [IOS] Unity Crashes on Startup with Deep Link Launch EXC_BAD_ACCESS (code=1, address=0x378) HOT 20
- Android 34 / FB SDK - can't build ( A failure occurred while executing com.android.build.gradle.internal.tasks.Workers$ActionFacade ) HOT 6
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from facebook-sdk-for-unity.