Skip to content

Instantly share code, notes, and snippets.

Last active October 10, 2021 12:27
What would you like to do?
Notes about Ruby 3.0 on FreeBSD


Gems don't install if you try to use:

cat /etc/make.conf 

The example port used to show this is devel/rubygems-racc.


A patch to upgrade ruby-gems to can be found here One issue still persisting is that no spec files can be found meaing they are extracted wrong?

devel/ruby-gems should be probably be updatet to something newer or at least this patch should be applied

gem install

For some reason gem install stoped creating a spec, cache and doc dir.

A quick fix is in Mk/Uses/ to patch this:

-GEMSPEC=       ${PORTNAME}.gemspec


+       @(mkdir -p ${STAGEDIR}${PREFIX}/${SPEC_DIR})
+       @(mkdir -p ${STAGEDIR}${PREFIX}/${CACHE_DIR})
+       @(mkdir -p ${STAGEDIR}${PREFIX}/${DOC_DIR})

The real fix should probably fix ? devel/ruby-gems ? in a way gem install ensures the creation of this directories at least that is the assumption since it worked for ruby27 and it works for ruby30 on linux.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment