LoginSignup
0
0

More than 1 year has passed since last update.

rails newでコケたときの備忘 m1 mac macOS 12.1

Posted at

書いた理由

備忘のため。
ググってもダイレクトに出てこなかったので、同じところで詰まっている人の参考になれば。

起こったこと

rails new
を叩いたら以下のメッセージでコケた

/Users/hoge/.rbenv/versions/2.7.4/lib/ruby/gems/2.7.0/gems/bootsnap-1.9.4/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:23:in `require': 
dlopen(/Users/hoge/.rbenv/versions/2.7.4/lib/ruby/gems/2.7.0/gems/bootsnap-1.9.4/lib/bootsnap/bootsnap.bundle, 0x0009): 
tried: '/Users/hoge/.rbenv/versions/2.7.4/lib/ruby/gems/2.7.0/gems/bootsnap-1.9.4/lib/bootsnap/bootsnap.bundle' (mach-o file, but is an incompatible architecture (have 'x86_64', need 'arm64e')), 
'/usr/local/lib/bootsnap.bundle' (no such file), '/usr/lib/bootsnap.bundle' (no such file) - /Users/hoge/.rbenv/versions/2.7.4/lib/ruby/gems/2.7.0/gems/bootsnap-1.9.4/lib/bootsnap/bootsnap.bundle (LoadError)

解決したこと

railsのアップデート

gem install rails

補足

rails tutorialを進めるにあたって、railsのバージョンを古いもので指定で入れていたので、
そのあたりがm1 macと折り合いが悪かったのではないかと推定。

0
0
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
0
0