I’m working on creating a GitHub Pages site and ran into an issue during Jekyll setup on my Mac. I installed the required tools including Homebrew, chruby, and Jekyll following the official documentation.
My current setup shows:
ruby -vreturnsruby 3.1.2p20 (2022-04-12 revision 4491bb740a) [x86_64-darwin18]chruby -Vshowschruby: 0.3.9- Jekyll installation completed successfully with
gem install jekyll
However, whenever I try to run jekyll -v or any Jekyll command, I get this error:
<internal:/Users/myuser/.rubies/ruby-3.1.2/lib/ruby/3.1.0/rubygems/core_ext/kernel_require.rb>:85:in `require': dlopen(/Users/myuser/.gem/ruby/3.1.2/gems/google-protobuf-3.21.12-x86_64-darwin/lib/google/3.1/protobuf_c.bundle, 9): no suitable image found. Did find: (LoadError)
/Users/myuser/.gem/ruby/3.1.2/gems/google-protobuf-3.21.12-x86_64-darwin/lib/google/3.1/protobuf_c.bundle: cannot load 'protobuf_c.bundle' (load command 0x80000034 is unknown)
I’ve tried switching to rvm instead of chruby and tested different Ruby versions like 3.1.3 and 3.2.0, but the same protobuf_c loading error persists. This is my first time working with Ruby and Jekyll, so I’m not sure what’s causing this issue or how to fix it.