-
Notifications
You must be signed in to change notification settings - Fork 92
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
Error loading plugin on M1 mac #217
Comments
I don't have an M1 Mac and I don't use this library day-to-day anymore, so I don't really have the capacity or ability to help fix this. I know you said Ruby is unfamiliar, but with some digging I have no doubt you could resolve this problem, either by fixing the underlying issue with the build architecture, or workaround around it by using x86 emulation for the whole CocoaPods chain. It seems daunting at first but I bet you could do it, and write a really satisfying blog post afterwards too 😉 If you're keen, I can put a call our on Twitter for someone to offer assistance. Good luck! |
I am having the exact same issue 😭😭😭 @ashfurrow @simonmcl please let me know if you find some solution :/ |
Okay @simonmcl, I think try opening the terminal with Rosetta and it will work for you! It worked for me 😊 |
@midhetfatema94 Hi there, would you kindly tell the rest of us how you managed to resolve the issue? Thank you in advance. |
The thing I actually did was open Terminal in Rosetta. (You can Click Cmd+option+i) in the Finder after selecting Terminal. This run the cocoapods-key plugin without any problems but did not make any changes. So I then cloned my repo on my Intel Macbook > installed the key > airdropped it to my m1! I realize that this solution is not optimal, I had to do what I had to do 🙈 |
@midhetfatema94 Thank you very much for the reply! Even though I made it work without doing what you did, I figured this might help someone else and here is the steps I taken.
|
Does anyone have a solution for this issue or found what could be the problem? We are using Cocoapods Keys, and unfortunately it does not work. Using cocoa pods with home brew and then installing cocoa pods keys does not work as well, cocoa pods does not recognise the plugin. |
Hi @dyegos, Although the problem is clear that the build is not compatible with the new M1 system architecture, a solution has not been discovered yet. What you can do to make your cocoapod keys work is use XCode & Terminal in Rosetta. |
Thank you for your comment @midhetfatema94! I wish I could help with something, to make it work in M1. I think I don't have enough knowledge for that. Thank you. |
Hi @midhetfatema94, running the Terminal and XCode in Rosetta didn't help us, perhaps because we still need to install command-line tools for the x86 mode (xcode-select --install on the terminal in rosetta mode). We'll see if it helps, anyway, the pod doesn't install for now and we're stuck. |
@kluku also trying adding the architecture config to your target. Be careful if you are using this with a CI/CD deployment and the environment setup on the build server is different from yours... This could create some deployment issues. |
I got it to work using Homebrew, rbenv and bundler all of it with arch commands. No Rosetta needed. |
@dyegos could you share please!! |
Update: 10/28/21 I tried every suggestion after many hours of troubleshooting and the only solution that worked for me was following @jiayangmiao instructions above. Make sure you install ruby |
@xanderbuck These are the steps I used. I attached the file. I hope it helps someone else. 10/29/2021 If after doing that you have any problem with LLDB in Xcode, please run Credits to https://github.com/igorcferreira |
Thanks to @xanderbuck and @jiayangmiao
|
@jiayangmiao @yostyle |
Thank you, @yostyle! 💯 |
I don't remember the details, but it was not 3.0 because my intel Mac at that time worked and it was running something 2.x, and the Mac usually comes with a ruby release that's 2.x as well. I probably was running under some other restrictions for other libraries, and additionally looked at the dependencies of other libraries that were emitting error. Now I don't interact with this library for my work so the memory is not fresh, but one day I might revisit this and write up something about it. |
Hi, I've tried the solution described above that involves installing Ruby 2.7.3 with Error: Downloading openssl-1.1.1q.tar.gz...
-> https://dqw8nmjcqpjn7.cloudfront.net/d7939ce614029cdff0b6c20f0e2e5703158a489a72b2507b8bd51bf8c8fd10ca
Installing openssl-1.1.1q...
BUILD FAILED (macOS 12.4 using ruby-build 20220710)
Inspect or clean up the working tree at /var/folders/6m/m0blyx852ysfp214tcvv3m_40000gn/T/ruby-build.20220714161205.75382.xdcE3o
Results logged to /var/folders/6m/m0blyx852ysfp214tcvv3m_40000gn/T/ruby-build.20220714161205.75382.log
Last 10 log lines:
clang -Iinclude -arch x86_64 -O3 -Wall -D_REENTRANT -DZLIB -DZLIB_SHARED -DNDEBUG -I/Users/raffis/.rbenv/versions/2.7.3/include -MMD -MF test/verify_extra_test.d.tmp -MT test/verify_extra_test.o -c -o test/verify_extra_test.o test/verify_extra_test.c
clang -Iinclude -arch x86_64 -O3 -Wall -D_REENTRANT -DZLIB -DZLIB_SHARED -DNDEBUG -I/Users/raffis/.rbenv/versions/2.7.3/include -MMD -MF test/versions.d.tmp -MT test/versions.o -c -o test/versions.o test/versions.c
test/v3ext.c:201:24: error: implicitly declaring library function 'memcmp' with type 'int (const void *, const void *, unsigned long)' [-Werror,-Wimplicit-function-declaration]
if (!TEST_true(memcmp(ip1->data, ip2->data, ip1->length) <= 0))
^
test/v3ext.c:201:24: note: include the header <string.h> or explicitly provide a declaration for 'memcmp'
1 error generated. Current setup: |
Hello, I too have tried the above solution of installing Ruby 2.7.3 via rbenv - I get as far as running:
After running
Current setup: |
Its save my time. Thanks bro. |
Same issue here. I have tried all the stuff:
I'm about to remove |
Unfortunately I couldn't find a solution either and I had to remove it too. It's a shame because it was a good project. |
Your Podfile requires that the plugin I have this error in M1 MAX & Monterey 12.6.1 & Xcode 14.1 & ruby version 3.1.2 I couldn't solve this problem with all possible solutions |
@magnett so what did you use in place of cocoapods-keys? I'm about ready to ditch it myself. |
Please checkout my PR: #235 |
I've just gotten an M1 mac and trying to install everything and run a project that uses cocoapods keys. Its working if I run pod install with
Other users on this thread: CocoaPods/CocoaPods#9907 are reporting that if you update the pre-installed ruby version to at least 2.7.3, that it all works natively without the new for
arch -x86_64
. However when I do that, i get an error thatruby_inline/ruby-2.6.0
is not compatible.I know nothing bout ruby or these tools. I'm assuming the inline version of ruby needs to be updated. Is this something you could do and cut a new release?
The text was updated successfully, but these errors were encountered: