Framework Not Found with xcode 12

With xcode 12 first time build fails for working project with previously installed cocoapods framework:
ld: framework not found Pods_CopticFind
clang: error: linker command failed with exit code 1 (use -v to see invocation)

So, what changed from xcode 11.7 to 12?

Tried running:
pod deintegrate
pod update
No change, still same error.

2. Change Framework Search path to 'recursive'.
No change, still same error.

Accepted Reply

Solved by adding arm64 to Excluded Architectures (EXCLUDED_ARCHS) in the Project settings. Looks like we need to do this until the pod in question supports arm64.

  • Same problem ,and add Any IOS Simulator SDL = arm64, but Framework not found GoogleMapsCore. No have error in my imac i5 but now in imac M1 have this error, pods are update and install, but same error. IOS 11

    BEST REGARDS

Add a Comment

Replies

Solved by adding arm64 to Excluded Architectures (EXCLUDED_ARCHS) in the Project settings. Looks like we need to do this until the pod in question supports arm64.

  • Same problem ,and add Any IOS Simulator SDL = arm64, but Framework not found GoogleMapsCore. No have error in my imac i5 but now in imac M1 have this error, pods are update and install, but same error. IOS 11

    BEST REGARDS

Add a Comment
added arm64 to Excluded Architectures (EXCLUDED_ARCHS) in the Project settings but still not working in xcode 12.1
We still facing the same problem. Adding arm64 to the excluded architecture doesn't fix the problem.
But, if you need to make archive process it's not going to work, at first you need to specify arch 64 only simulator SKK - ref: https://stackoverflow.com/questions/63607158/xcode-12-building-for-ios-simulator-but-linking-in-object-file-built-for-ios
I (using XCode 12.4 on my dev environment and App Center pipeline that uses Xcode2.2) have tried all the suggestions on this thread and also the one SO link. None of them have fixed my issue. The app now runs on simulator as well as on device but fails consistently to archive using generic setting Any iOS Device (arm64 armv7). The error shows up after it hits command  ~\clang -target armv7-apple-ios10.0 giving the error ld: framework not found Pods_*** Can someone suggest some pointer to me?

Solved, Build Settings > Build Active Architecture Only = Yes

If you run it with AppName.xcworkspace not from the AppName.xcodeproj project after the pod is installed

  • this suggestion worked for me!!

Add a Comment

As @hishak noted adding this to end of my pod file fixed the error:

post_install do |installer|
   installer.pods_project.targets.each do |target|
    target.build_configurations.each do |config|
      config.build_settings["EXCLUDED_ARCHS[sdk=iphonesimulator*]"] = "arm64 i386"
   end
   end
 end

Ref: https://github.com/flutter/flutter/issues/94914#issuecomment-992898782

@Aminit Adding that code to the end of my podfile also fixed the error.

I have enabled "Open using Rosetta" and run. Not sure if it makes sense, but this is working.