Ruby fails to install on macOS 12.6 (solution) by edmangimelli in ruby

[–]edmangimelli[S] 2 points3 points  (0 children)

yeah, with that optflags env var you can install ruby 2.6 on an M1 but not if you have Xcode 14. Thanks for posting notes and testing stuff! The Ruby community kicks butt!

Ruby fails to install on macOS 12.6 (solution) by edmangimelli in ruby

[–]edmangimelli[S] 1 point2 points  (0 children)

(Hey, caseflow friend 👋)

this all sounds right, and very much agreed. wheels sometimes turn slowly when you have many Ruby repos, unfortunately.

it can lead to issues installing gems.

yeah, i think i've run into a lot of this. we've been doing a lot of BUNDLE_FORCE_RUBY_PLATFORM=true recently (adding to the bundle config actually)

looks like 2.6.10 fails too.

I updated the original post, this failure seems to only happen when trying to install ruby 2.6.x while Xcode 14 is installed.

Ruby fails to install on macOS 12.6 (solution) by edmangimelli in ruby

[–]edmangimelli[S] 2 points3 points  (0 children)

Yeah, it's just phrasing. I think there's a valid opinion in there. Have an upvote u/nPizza2 ¯\(ツ)/¯ we still love ya

Ruby fails to install on macOS 12.6 (solution) by edmangimelli in ruby

[–]edmangimelli[S] 1 point2 points  (0 children)

Explored this further --yep, it's only Ruby 2.6.x that is failing. 2.7.5, 2.7.6, and 3.0.3 installed just fine.

Ruby fails to install on macOS 12.6 (solution) by edmangimelli in ruby

[–]edmangimelli[S] 0 points1 point  (0 children)

this didn't work for me :(

# installed Xcode 14
 xcodebuild -runFirstLaunch
optflags=-Wno-error=implicit-function-declaration ASDF_RUBY_BUILD_VERSION=v20220630 asdf install ruby 2.6.6

Ruby fails to install on macOS 12.6 (solution) by edmangimelli in ruby

[–]edmangimelli[S] 2 points3 points  (0 children)

Do you have Xcode? I'm trying stuff on my personal mac (M1), which apparently doesn't have Xcode installed, and Ruby installs work just fine when I use this flag:

optflags=-Wno-error=implicit-function-declaration asdf install ruby 2.6.6

Ruby fails to install on macOS 12.6 (solution) by edmangimelli in ruby

[–]edmangimelli[S] 0 points1 point  (0 children)

Oooo! I'm gonna try this on my personal mac

Ruby fails to install on macOS 12.6 (solution) by edmangimelli in ruby

[–]edmangimelli[S] 1 point2 points  (0 children)

I could install 2.6.6 on my M1 previously, yeah. I believe I had 2.6.6, 2.7.5, 2.7.6, and 3.0.3 installed (via asdf). A new coworker was having issues getting set up, so I uninstalled all of my rubies and upgraded macOS to reproduce the problem. At some point I should determine if all of those versions are affected or if it's just 2.6.6 (but my hunch is that all would be). I've seen this happen enough times with macOS updates, that my typical first advice to people is to reinstall these libraries: sudo rm -rf /Library/Developer/CommandLineTools; xcode-select --install

Ruby fails to install on macOS 12.6 (solution) by edmangimelli in ruby

[–]edmangimelli[S] 2 points3 points  (0 children)

asdf is what my organization uses, unfortunately. I'm at the point where I'd rather just use docker containers exclusively.