Apple Mach-O Linker (ld) Error: Linker Command Failed

Apple Mach-O Linker (ld) Error: Linker Command Failed
Hey, I’d really like to see an answer on this. I have the same problem and I can’t get around it.

Summation
If I enable Unity Ads in the Services panel I get this error and the game won’t archive using Xcode. If I turn off Unity Ads from the, then it’ll archive in XCode but iOS will reject it because this is a children’s game. I have the Unity Ads from the Asset Store installed. That seems to be a problem. I cannot seem to have both the Services tab enabled and the package manager “pacman” installed. If I remove the pacman, I get too many errors and my game will not run in Unity.

5668777--590644--upload_2020-4-3_21-56-26.png

My Info
I’ve updated Unity to version 2019.3.7f1 and Xcode version 11.3.1.

Referenced Posts and Attempts
Attempt #1
his post mentions two things I have no idea where they are, maybe that will help or maybe its mentioning features only available in the referenced outdated version of Unity? 1. choose in player setting under other settings : universal platform and IL2CPP 2. update all plugins as these need to support arm64

Attempt #2
Next, I tried what this post mentioned which was enabling module and disable bitcode: Apple Mach-O Linker (Id) Error... - Questions & Answers - Unity Discussions

Attempt #3
set the Scripting Backend to IL2CPP (Defaults to Mono (2.x)) and Architecture to Universal as mentioned here: https://answers.unity.com/questions/788331/xcode-511-missing-architectures-arm64.html?_ga=2.208111634.1688457181.1585673871-1609956356.1584999078

Attempt #4
reset architecture settings to standard and build active architecture as this mentions: ios - Xcode 5.1: missing required architecture arm64 - Stack Overflow

Attempt #5
deleted the library search paths as mentioned here: iphone - Apple Mach-O Linker Warning Directory not found - Stack Overflow

Attempt #6
'm not really willing to downgrade Xcode as this suggests: Apple Mach-O Linker Error when Building - Questions & Answers - Unity Discussions

Attempt #7
tried changing the … thingy up in the top left…it’s like a button that states [Unity iPhone > iPhone] as opposed to a simulator or “General Device”. (Looks like @MrRetroCentral put the solution that worked for him on many posts). Apple Mach-O linker Error - Questions & Answers - Unity Discussions Apple Mach-O Linker (Id) Error - Questions & Answers - Unity Discussions Apple Mach-O linker error during build - Questions & Answers - Unity Discussions Unity 4.6Beta Mach-O Linker Errors - Questions & Answers - Unity Discussions

Attempt #8
omeone here mentioned using some Native Sharing Plugins from a Github Repo, but I don’t know how to use them: GitHub - NicholasSheehan/Unity-Native-Sharing: A Unity plugin to open native sharing dialogs on iOS and Android, primarily for text and files

Attempt #9
ere @rathodjignesh1805 merely tells you to expand two things, which…not sure how that’s helpful. I think we’re missing a step on what to do with the expanded sections. Apple Mach-O Linker (ld) Error Group - Questions & Answers - Unity Discussions

Attempt #10
ince my issue is related to Duplicate Architecture Symbols, I switched No Common Blocks to ‘No’ and I still get the Apple Mach-O Linker Error. iphone - duplicate symbols for architecture armv7 - Stack Overflow

Attempt #11
ran the pack uninstaller as someone recommended in this post yet found I don’t have anything called ‘Ads’ at all: Unity Ads error from Unity to Xcode build - Stack Overflow

Other People’s Attempts to Ask Answer.Unity.com
ere are posts from poor souls who never got an answer: https://answers.unity.com/questions/1574708/how-to-solve-xcode-apple-mach-o-linker-id-error.html

https://answers.unity.com/questions/1075727/apple-mach-o-linker-id-errors.html

https://answers.unity.com/questions/534784/apple-mach-o-linker-error-in-xcode-due-to-game-cen.html

https://answers.unity.com/questions/1345370/xcode-apple-mach-o-linker-error-library-not-found.html

https://answers.unity.com/questions/180064/apple-mach-o-linker-error.html

Ld Message
Ld /Users/willmcintosh/Library/Developer/Xcode/DerivedData/Unity-iPhone-ddlfyztfvtuckegewmdyiaaikrmz/Build/Intermediates.noindex/ArchiveIntermediates/Unity-iPhone/IntermediateBuildFilesPath/UninstalledProducts/iphoneos/UnityFramework.framework/UnityFramework normal arm64 (in target ‘UnityFramework’ from project ‘Unity-iPhone’)
cd /Users/willmcintosh/Desktop/FarmyardFeeder006
/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/clang++ -target arm64-apple-ios10.0 -dynamiclib -isysroot /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS13.2.sdk -L/Users/willmcintosh/Library/Developer/Xcode/DerivedData/Unity-iPhone-ddlfyztfvtuckegewmdyiaaikrmz/Build/Intermediates.noindex/ArchiveIntermediates/Unity-iPhone/BuildProductsPath/Release-iphoneos -L/Users/willmcintosh/Desktop/FarmyardFeeder006/Libraries -F/Users/willmcintosh/Library/Developer/Xcode/DerivedData/Unity-iPhone-ddlfyztfvtuckegewmdyiaaikrmz/Build/Intermediates.noindex/ArchiveIntermediates/Unity-iPhone/BuildProductsPath/Release-iphoneos -F/Users/willmcintosh/Desktop/FarmyardFeeder006/Frameworks/Plugins/iOS -filelist /Users/willmcintosh/Library/Developer/Xcode/DerivedData/Unity-iPhone-ddlfyztfvtuckegewmdyiaaikrmz/Build/Intermediates.noindex/ArchiveIntermediates/Unity-iPhone/IntermediateBuildFilesPath/Unity-iPhone.build/Release-iphoneos/UnityFramework.build/Objects-normal/arm64/UnityFramework.LinkFileList -install_name @rpath/UnityFramework.framework/UnityFramework -Xlinker -rpath -Xlinker @executable_path/Frameworks -Xlinker -rpath -Xlinker @loader_path/Frameworks -Xlinker -map -Xlinker /Users/willmcintosh/Library/Developer/Xcode/DerivedData/Unity-iPhone-ddlfyztfvtuckegewmdyiaaikrmz/Build/Intermediates.noindex/ArchiveIntermediates/Unity-iPhone/IntermediateBuildFilesPath/Unity-iPhone.build/Release-iphoneos/UnityFramework.build/UnityFramework-LinkMap-normal-arm64.txt -dead_strip -Xlinker -object_path_lto -Xlinker /Users/willmcintosh/Library/Developer/Xcode/DerivedData/Unity-iPhone-ddlfyztfvtuckegewmdyiaaikrmz/Build/Intermediates.noindex/ArchiveIntermediates/Unity-iPhone/IntermediateBuildFilesPath/Unity-iPhone.build/Release-iphoneos/UnityFramework.build/Objects-normal/arm64/UnityFramework_lto.o -stdlib=libc++ -fobjc-arc -fobjc-link-runtime -weak_framework CoreMotion -weak-lSystem -liPhone-lib -framework Security -framework MediaToolbox -framework CoreText -framework AudioToolbox -weak_framework AVFoundation -framework AVKit -framework CFNetwork -framework CoreGraphics -framework CoreMedia -weak_framework CoreMotion -framework CoreVideo -framework Foundation -framework OpenAL -framework OpenGLES -framework QuartzCore -framework SystemConfiguration -framework UIKit -liconv.2 -lil2cpp -framework UnityAds -framework AdSupport -framework CoreTelephony -framework StoreKit -weak_framework Metal -Xlinker -dependency_info -Xlinker /Users/willmcintosh/Library/Developer/Xcode/DerivedData/Unity-iPhone-ddlfyztfvtuckegewmdyiaaikrmz/Build/Intermediates.noindex/ArchiveIntermediates/Unity-iPhone/IntermediateBuildFilesPath/Unity-iPhone.build/Release-iphoneos/UnityFramework.build/Objects-normal/arm64/UnityFramework_dependency_info.dat -o /Users/willmcintosh/Library/Developer/Xcode/DerivedData/Unity-iPhone-ddlfyztfvtuckegewmdyiaaikrmz/Build/Intermediates.noindex/ArchiveIntermediates/Unity-iPhone/IntermediateBuildFilesPath/UninstalledProducts/iphoneos/UnityFramework.framework/UnityFramework

Error Message
I get the following error message:

1 Like

Got it. Unity Editor > Cloud > Services > Enable Ads > Advanced > DISABLE plugins (if you have the Unity Ads 2.0 SDK package installed from the Asset Store).

2 Likes