DEV Community

olistik
olistik

Posted on

1

Compiling Ruby 3.3 on OpenBSD 7.4

Resuming the work done for

https://dev.to/olistik/a-naive-installation-of-ruby-and-rails-on-openbsd-4d50

I wanted to test the latest Ruby 3.3.0 on the latest OpenBSD 7.4 and here are the results.

First of all, let's download the sources:

$ curl -LO https://cache.ruby-lang.org/pub/ruby/3.3/ruby-3.3.0.tar.gz
$ tar xvfz ruby-3.3.0.tar.gz
$ cd ruby-3.3.0
Enter fullscreen mode Exit fullscreen mode

Add libyaml dependency if you don't have it already:

$ doas pkg_add libyaml
Enter fullscreen mode Exit fullscreen mode

Configure the compilation so that it picks libyaml and it outputs the binaries in our rubies directory:

$ CONFIGURE_ARGS="--with-libyaml-dir=/usr/local/lib" ./configure  --prefix ~/.rubies/3.3.0
$ make
$ make install
Enter fullscreen mode Exit fullscreen mode

Update the symlink for the current version:

$ cd $HOME/rubies
$ rm current
$ ln -s /home/$HOME/.rubies/3.3.0/ current
Enter fullscreen mode Exit fullscreen mode

And then check if everything works as expected:

$ ruby -v
ruby 3.3.0 (2023-12-25 revision 5124f9ac75) [x86_64-openbsd7.4]
Enter fullscreen mode Exit fullscreen mode

Image of Docusign

🛠️ Bring your solution into Docusign. Reach over 1.6M customers.

Docusign is now extensible. Overcome challenges with disconnected products and inaccessible data by bringing your solutions into Docusign and publishing to 1.6M customers in the App Center.

Learn more

Top comments (0)

A Workflow Copilot. Tailored to You.

Pieces.app image

Our desktop app, with its intelligent copilot, streamlines coding by generating snippets, extracting code from screenshots, and accelerating problem-solving.

Read the docs