How to fix a library not found error on Xcode - xcode

I use Xcode 11.3.1.
I receive an Xcode project from a coworker that is using Xcode 12.4.
I open the project and try to build it.
I receive the following error:
Library not found for ISO8601DateFormatterValueTransformer
Inside Xcode there are some details:
ld: warning: directory not found for option '-L/Users/catalina/Library/Developer/Xcode/DerivedData/CDA-chskvgcrkhxpgnghuarozjoeymbq/Build/Products/Debug-iphonesimulator/ISO8601DateFormatterValueTransformer'
ld: warning: directory not found for option '-L/Users/catalina/Library/Developer/Xcode/DerivedData/CDA-chskvgcrkhxpgnghuarozjoeymbq/Build/Products/Debug-iphonesimulator/RKValueTransformers'
ld: warning: directory not found for option '-L/Users/catalina/Library/Developer/Xcode/DerivedData/CDA-chskvgcrkhxpgnghuarozjoeymbq/Build/Products/Debug-iphonesimulator/RestKit'
ld: warning: directory not found for option '-L/Users/catalina/Library/Developer/Xcode/DerivedData/CDA-chskvgcrkhxpgnghuarozjoeymbq/Build/Products/Debug-iphonesimulator/SOCKit'
ld: warning: directory not found for option '-L/Users/catalina/Library/Developer/Xcode/DerivedData/CDA-chskvgcrkhxpgnghuarozjoeymbq/Build/Products/Debug-iphonesimulator/TransitionKit'
ld: warning: directory not found for option '-L/Users/catalina/Library/Developer/Xcode/DerivedData/CDA-chskvgcrkhxpgnghuarozjoeymbq/Build/Products/Debug-iphonesimulator/ZBarSDK'
ld: library not found for -lISO8601DateFormatterValueTransformer
clang: error: linker command failed with exit code 1 (use -v to see invocation)
My coworker said to me to delete the Pods folder and run the pod install command. After running the command some libraries are installed on the project.
But when I try to build the project, it fails.
This problem could be related to my Xcode version? I mean, I was trying to compile a project using an old version of Xcode
Or
this is a problem related to not importing correctly the Library?

I find out what was causing the problem.
I open the xcproject file. The correct file to open the project is the xcworkspace file.
The problem is fixed now.

Related

After Cocoapod update: "No such file or directory: 'FirebaseAnalytics'"

I'm getting this error after updating the Firebase pods on Xcode 12.5.1, everything was working fine before clang: error: no such file or directory: 'FirebaseAnalytics'
It started after I deleted the linker flag as described below. Initially I was getting a Framework not found FIRAnalyticsConnector error, so I followed the solution from here (with image below): Framework not found FIRAnalyticsConnector from Xcode 12.4
So I deleted the FIRAnalyticsConnector Linker flag as described, it got rid of the previous error but then after that I get the clang: error: no such file or directory: 'FirebaseAnalytics' error.
Here's my targets:
And when I click on add dependencies the FirebaseAnalytics is greyed out:
So my question is how do I fix the clang: error: no such file or directory: 'FirebaseAnalytics' error? Thanks.

Errors Compiling xcode and FBSDK

When creating an assembly produces an error.
if through .cdworkspace
duplicate symbol _OBJC_IVAR_$_FBSDKDeviceLoginCodeInfo._verificationURL in:
/Users/admin/Library/Developer/Xcode/DerivedData/Unity-iPhone-hiyuaervseeqdjddnyzvacrngstr/Build/Products/ReleaseForRunning-iphoneos/FBSDKLoginKit/libFBSDKLoginKit.a(FBSDKDeviceLoginCodeInfo.o)
/Users/admin/Desktop/ios_idle/Frameworks/FacebookSDK/Plugins/iOS/FBSDKLoginKit.framework/FBSDKLoginKit(FBSDKDeviceLoginCodeInfo.o)
ld: 1197 duplicate symbols for architecture arm64
clang: error: linker command failed with exit code 1 (use -v to see invocation)
if through .xcodeproj
ld: warning: directory not found for option '-L/Users/admin/Library/Developer/Xcode/DerivedData/Unity-iPhone-aznohbyfwguqcwgiyilrfrsrcddz/Build/Products/ReleaseForRunning-iphoneos/FBSDKCoreKit'
ld: warning: directory not found for option '-L/Users/admin/Library/Developer/Xcode/DerivedData/Unity-iPhone-aznohbyfwguqcwgiyilrfrsrcddz/Build/Products/ReleaseForRunning-iphoneos/FBSDKLoginKit'
ld: warning: directory not found for option '-L/Users/admin/Library/Developer/Xcode/DerivedData/Unity-iPhone-aznohbyfwguqcwgiyilrfrsrcddz/Build/Products/ReleaseForRunning-iphoneos/FBSDKShareKit'
ld: library not found for -lBolts
clang: error: linker command failed with exit code 1 (use -v to see invocation)
how fix it?
I deleted everything in the FacebookSDK folder in my project except for the file FacebookSDK/SDK/Resources/FacebookSettings. I saved this file so I wouldn't have to re add my settings again later. Then I reimported the Facebook SDK.
It seems that the SDK has had some significant hierarchical changes in the recent versions. When updating to one of the newer versions it did not remove all of the redundant files properly, leading to duplicate classes across across the different versions.

No such file or directory when archiving

I added Firebase to my Xcode project using cocoapods. I can build and it succeeds, I only get this warning:
ld: warning: directory not found for option '-F/Users/.../Library/Developer/Xcode/DerivedData/game-dwgqybwtgjx..../Build/Intermediates/ArchiveIntermediates/game/BuildProductsPath/Release-iphoneos/GoogleToolboxForMac'
ld: warning: directory not found for option '-F/Users/.../Library/Developer/Xcode/DerivedData/game-dwgqybwtgj..../Build/Intermediates/ArchiveIntermediates/game/BuildProductsPath/Release-iphoneos/Protobuf'
The build succeeds but the archive doesn't.
When I click archive I get these warnings and errors:
/Users/..../Library/Developer/Xcode/DerivedData/game-dwgqybwtg.../Build/Intermediates/ArchiveIntermediates/game/InstallationBuildProductsLocation/Applications/game.app/Frameworks/GoogleToolboxForMac.framework: No such file or directory
Managed to fix the problem by updating macOS and Xcode

ld: warning: directory not found for option '-F-'

I know this has been probably asked a thousands of times, but I can't get a rid of this error upon building. I think they started to show up after I upgraded Xcode to the latest version available (6.3.2).
ld: warning: directory not found for option '-F-'
ld: library not found for -lPods-AcknowledgementsBundle
clang: error: linker command failed with exit code 1 (use -v to see invocation)
my Library Search Path (target) has:
$(inherited) non-recursive
$(PROJECT_DIR) non-recursive
I uninstalled and installed back the pod, clean and build.. nothing.
Does anybody have a good suggestion?
Thanks!

Unexplained Apple Mach-O liner warning error

Yesterday i integrated Google's Admobs fine into my Xcode 6.1 project. Everything worked. Today i open Xcode and i receive the following errors...
ld: warning: directory not found for option '-L/Users/Marco/Desktop/SpaceAlien copy 1/Space
ld: warning: directory not found for option '-LAlien'
ld: library not found for -lGoogleAdMobAds
It's 2 yellow warning errors and the RED error doesn't let me build project = GoogleAdMobAds
So I read in Project Navigator for libGoogleAdMobAds.a in target membership to unclick and then click back the check. That works and project builds. However, when i close project open it again, I get the same error. How do I make this error remove permanently? Also, for the ld: warning: directory not found errors I went to build setting then library search paths and i CAN'T delete anything, don't know what to do. Please HELP!
ld: warning: directory not found for option '-L/Users/Marco/Desktop/SpaceAlien copy 1/Space
Problem is because the path contains spaces. Try using quotes with the path: "Users/Marco/Desktop/SpaceAlien copy 1/Space"
or you can use escape "\" character to "fix" the path:
Users/Marco/Desktop/SpaceAlien\ copy\ 1/Space

Resources