I'm trying to install stringio 3.0.6 as a part of project dependencies tree via bundle install, but apparently it does not work as it should because of the error mach-o file, but is an incompatible architecture (have 'x86_64', need 'arm64')
.
The full stacktrace is below:
<internal:/Users/sviat/.rvm/rubies/ruby-3.1.2/lib/ruby/3.1.0/rubygems/core_ext/kernel_require.rb>:85:in
`require':
dlopen(/Users/sviat/.rvm/gems/ruby-3.1.2/gems/stringio-3.0.6/lib/stringio.bundle, 0x0009):
tried: '/Users/sviat/.rvm/gems/ruby-3.1.2/gems/stringio-3.0.6/lib/stringio.bundle'
(mach-o file, but is an incompatible architecture (have 'x86_64', need 'arm64')),
'/System/Volumes/Preboot/Cryptexes/OS/Users/sviat/.rvm/gems/ruby-3.1.2/gems/stringio-3.0.6/lib/stringio.bundle' (no such file), '/Users/sviat/.rvm/gems/ruby-3.1.2/gems/stringio-3.0.6/lib/stringio.bundle'
(mach-o file, but is an incompatible architecture (have 'x86_64', need 'arm64')) -
/Users/sviat/.rvm/gems/ruby-3.1.2/gems/stringio-3.0.6/lib/stringio.bundle (LoadError)
I'm constantly getting the error above despite I have done everything below:
- Set
bundle config set force_ruby_platform true
; - Installed Ruby with ruby -v prints
ruby 3.1.2p20 (2022-04-12 revision 4491bb740a) [arm64-darwin22]
; - Using ZSH with proper config in it and
source ~/.zshrc
. - Using ARM terminal with uname -m says
arm64
. - I can install stingio with
gem list stringio
, but not witharch -arm64 gem install stringio
. The error will be as above. - Rozetta is not turned on in Terminal setting.
What else I can try? I've reinstalled my ruby and tried to do the same with RBENV, etc. Restarted my laptop and switched the electricity without any success.
MacOS - Ventura 13.4; Chip - M1. Ruby - 3.1.2. RVM - latest. Terminal - arm64.