Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

17.0 build failed #720

Open
5 tasks done
stzseungmokyun opened this issue Apr 22, 2024 · 9 comments
Open
5 tasks done

17.0 build failed #720

stzseungmokyun opened this issue Apr 22, 2024 · 9 comments
Labels

Comments

@stzseungmokyun
Copy link

stzseungmokyun commented Apr 22, 2024

Checklist

Environment

Describe your dev environment here, giving as many details as possible. If you have them, make sure to include:

  • Unity Editor Version: 2022.3.22f1
  • Unity SDK Version: 17.0.0
  • Installation Platform & Verison: iOS version 17.4.1

Code Samples & Details

I get the following error when building xcode.
Build succeeds when downgrading Facebook SDK 15.1

ld: warning: ignoring duplicate libraries: '-lc++'
ld: warning: Could not find or use auto-linked framework 'CoreAudioTypes': framework 'CoreAudioTypes' not found
ld: Undefined symbols:
  _GADAdLoaderAdTypeNative, referenced from:
      ___73-[ALGoogleMediationAdapter loadAdViewAdForParameters:adFormat:andNotify:]_block_invoke in libGoogleAdapter.a[10](ALGoogleMediationAdapter.o)
      ___64-[ALGoogleMediationAdapter loadNativeAdForParameters:andNotify:]_block_invoke in libGoogleAdapter.a[10](ALGoogleMediationAdapter.o)
  _GADAdSizeBanner, referenced from:
      -[ALGoogleMediationAdapter adSizeFromAdFormat:isAdaptiveBanner:parameters:] in libGoogleAdapter.a[10](ALGoogleMediationAdapter.o)
      -[ALGoogleMediationAdapter adSizeFromAdFormat:isAdaptiveBanner:parameters:] in libGoogleAdapter.a[10](ALGoogleMediationAdapter.o)
  _GADAdSizeLeaderboard, referenced from:
      -[ALGoogleMediationAdapter adSizeFromAdFormat:isAdaptiveBanner:parameters:] in libGoogleAdapter.a[10](ALGoogleMediationAdapter.o)
  _GADAdSizeMediumRectangle, referenced from:
      -[ALGoogleMediationAdapter adSizeFromAdFormat:isAdaptiveBanner:parameters:] in libGoogleAdapter.a[10](ALGoogleMediationAdapter.o)
  _GADCurrentOrientationAnchoredAdaptiveBannerAdSizeWithWidth, referenced from:
      ___75-[ALGoogleMediationAdapter adSizeFromAdFormat:isAdaptiveBanner:parameters:]_block_invoke in libGoogleAdapter.a[10](ALGoogleMediationAdapter.o)
      +[ALGoogleMediationAdapter currentOrientationAchoredAdaptiveBannerSizeWithWidth:] in libGoogleAdapter.a[10](ALGoogleMediationAdapter.o)
  _GADGetStringFromVersionNumber, referenced from:
      -[ALGoogleMediationAdapter SDKVersion] in libGoogleAdapter.a[10](ALGoogleMediationAdapter.o)
  _OBJC_CLASS_$_GADAdLoader, referenced from:
       in libGoogleAdapter.a[10](ALGoogleMediationAdapter.o)
  _OBJC_CLASS_$_GADAppOpenAd, referenced from:
       in libGoogleAdapter.a[10](ALGoogleMediationAdapter.o)
  _OBJC_CLASS_$_GADBannerView, referenced from:
       in libGoogleAdapter.a[10](ALGoogleMediationAdapter.o)
  _OBJC_CLASS_$_GADExtras, referenced from:
       in libGoogleAdapter.a[10](ALGoogleMediationAdapter.o)
  _OBJC_CLASS_$_GADInterstitialAd, referenced from:
       in libGoogleAdapter.a[10](ALGoogleMediationAdapter.o)
  _OBJC_CLASS_$_GADMediaView, referenced from:
       in libGoogleAdapter.a[3](ALGoogleNativeAdDelegate.o)
  _OBJC_CLASS_$_GADMobileAds, referenced from:
       in libGoogleAdapter.a[10](ALGoogleMediationAdapter.o)
  _OBJC_CLASS_$_GADNativeAdImageAdLoaderOptions, referenced from:
       in libGoogleAdapter.a[10](ALGoogleMediationAdapter.o)
  _OBJC_CLASS_$_GADNativeAdView, referenced from:
       in libGoogleAdapter.a[7](ALGoogleNativeAd.o)
  _OBJC_CLASS_$_GADNativeAdViewAdOptions, referenced from:
       in libGoogleAdapter.a[10](ALGoogleMediationAdapter.o)
  _OBJC_CLASS_$_GADQueryInfo, referenced from:
       in libGoogleAdapter.a[10](ALGoogleMediationAdapter.o)
  _OBJC_CLASS_$_GADRequest, referenced from:
       in libGoogleAdapter.a[10](ALGoogleMediationAdapter.o)
  _OBJC_CLASS_$_GADRewardedAd, referenced from:
       in libGoogleAdapter.a[10](ALGoogleMediationAdapter.o)
  _OBJC_CLASS_$_GADRewardedInterstitialAd, referenced from:
       in libGoogleAdapter.a[10](ALGoogleMediationAdapter.o)
clang: error: linker command failed with exit code 1 (use -v to see invocation)

This is my pod file

platform :ios, '12.0'

target 'UnityFramework' do
  pod 'AppLovinMediationFacebookAdapter', '6.15.0.0'
  pod 'AppLovinMediationGoogleAdapter', '11.3.0.0'
  pod 'AppLovinSDK', '12.4.1'
  pod 'AppsFlyerFramework', '6.13.0'
  pod 'FBSDKCoreKit', '~> 17.0.0'
  pod 'FBSDKCoreKit_Basics', '~> 17.0.0'
  pod 'FBSDKGamingServicesKit', '~> 17.0.0'
  pod 'FBSDKLoginKit', '~> 17.0.0'
  pod 'FBSDKShareKit', '~> 17.0.0'
  pod 'Firebase/Analytics', '10.22.0'
  pod 'Firebase/Core', '10.22.0'
  pod 'Firebase/Crashlytics', '10.22.0'
  pod 'Google-Mobile-Ads-SDK', '11.3.0'
  pod 'OneSignalXCFramework', '3.12.9'
end
target 'Unity-iPhone' do
  pod 'OneSignalXCFramework', '3.12.9'
end
use_frameworks!
target 'OneSignalNotificationServiceExtension' do
  pod 'OneSignalXCFramework', '3.12.9'
end
post_install do |installer|
installer.generated_projects.each do |project|
project.targets.each do |target|
target.build_configurations.each do |config|
config.build_settings["ALWAYS_EMBED_SWIFT_STANDARD_LIBRARIES"] = "$(inherited)"
config.build_settings["LD_RUNPATH_SEARCH_PATHS"] = "$(inherited)"
end
end
end
end

@Vitalchek
Copy link

I faced a similar problem. I'll wait for an answer in this chat.

@N4TUR1NO
Copy link

+1

@eduribeiro-fanatee
Copy link

Same issue here

@Vladeng
Copy link

Vladeng commented Apr 24, 2024

+1

@stzseungmokyun
Copy link
Author

I turned on the “Link Framework Statically” option in “ios resolver settings” and the problem was solved.
image

@stanislavsmagin
Copy link

Have the same problem. But I can't use static linking. Waiting for an answer.

@GreatSociety
Copy link

Try add in post build script this code:

            var project = new PBXProject();
            project.ReadFromFile(projPath);
            string mainTargetGuid = project.GetUnityMainTargetGuid();
            project.AddBuildProperty(mainTargetGuid, "OTHER_LDFLAGS", "-ObjC");

Works for me

Some information about this flag: https://developer.apple.com/library/archive/qa/qa1490/_index.html

@umair6
Copy link

umair6 commented May 31, 2024

+1

@gagbaghdas
Copy link

The same issue. Is there any updates on this?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

9 participants