Closed luciancic closed 8 hours ago
The issue is caused by:
Ignoring ffi-1.15.3 because its extensions are not built. Try: gem pristine ffi --version 1.15.3
and
LoadError - dlopen(/Library/Ruby/Gems/2.6.0/gems/ffi-1.15.3/lib/ffi_c.bundle, 0x0009): tried: '/Library/Ruby/Gems/2.6.0/gems/ffi-1.15.3/lib/ffi_c.bundle' (mach-o file, but is an incompatible architecture (have 'x86_64', need 'arm64e')) - /Library/Ruby/Gems/2.6.0/gems/ffi-1.15.3/lib/ffi_c.bundle
This is because it is trying to install a library that is not compatible with arm64 macbooks (M1 and later), probably due to your cocoapods install (zsh may be using a different install than bash?).
The recommendation I see online is installing cocoapods with brew, e.g. https://stackoverflow.com/a/74292067
Just wanted to document this to save others time potentially. Feel free to close this.
I tried installing this lib on our project and that failed. My default shell is zsh. I tried with bash and it worked.
The install command with the error:
/usr/local/bin/pod install
CocoaPods : 1.10.1 Ruby : ruby 2.6.8p205 (2021-07-07 revision 67951) [universal.arm64e-darwin21] RubyGems : 3.0.3.1 Host : macOS 12.4 (21F79) Xcode : 13.4.1 (13F100) Git : git version 2.32.1 (Apple Git-133) Ruby lib dir : /System/Library/Frameworks/Ruby.framework/Versions/2.6/usr/lib Repositories : trunk - CDN - https://cdn.cocoapods.org/
cocoapods-deintegrate : 1.0.4 cocoapods-plugins : 1.0.0 cocoapods-search : 1.0.0 cocoapods-trunk : 1.5.0 cocoapods-try : 1.2.0
Error
βββ TEMPLATE END ββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
[!] Oh no, an error occurred.
Search for existing GitHub issues similar to yours: https://github.com/CocoaPods/CocoaPods/search?q=dlopen%28%2FLibrary%2FRuby%2FGems%2F2.6.0%2Fgems%2Fffi-1.15.3%2Flib%2Fffi_c.bundle%2C+0x0009%29%3A+tried%3A+%27%2FLibrary%2FRuby%2FGems%2F2.6.0%2Fgems%2Fffi-1.15.3%2Flib%2Fffi_c.bundle%27+%28mach-o+file%2C+but+is+an+incompatible+architecture+%28have+%27x86_64%27%2C+need+%27arm64e%27%29%29+-+%2FLibrary%2FRuby%2FGems%2F2.6.0%2Fgems%2Fffi-1.15.3%2Flib%2Fffi_c.bundle&type=Issues
If none exists, create a ticket, with the template displayed above, on: https://github.com/CocoaPods/CocoaPods/issues/new
Be sure to first read the contributing guide for details on how to properly submit a ticket: https://github.com/CocoaPods/CocoaPods/blob/master/CONTRIBUTING.md
Don't forget to anonymize any private data!
Looking for related issues on cocoapods/cocoapods... Searching for inspections failed: undefined method `map' for nil:NilClass error Command failed with exit code 1. info Visit https://yarnpkg.com/en/docs/cli/add for documentation about this command.