Skip to content

ruby: add Linux OpenSSL/libyaml env for rv-ruby versions#724

Open
worstell wants to merge 6 commits intocashapp:masterfrom
worstell:master
Open

ruby: add Linux OpenSSL/libyaml env for rv-ruby versions#724
worstell wants to merge 6 commits intocashapp:masterfrom
worstell:master

Conversation

@worstell
Copy link
Copy Markdown
Contributor

rv-ruby statically links OpenSSL and libyaml into its built-in extensions,
but gem native extensions recompile and dynamically link against the system
libs. Ubuntu 24.04 ships OpenSSL 3.0.x which is too old. Set
BUNDLE_BUILD__OPENSSL and LD_LIBRARY_PATH on Linux to use linuxbrew's
OpenSSL and libyaml. macOS is unaffected.

Amp-Thread-ID: https://ampcode.com/threads/T-019c9632-b6b8-724a-af79-d30573ba186a
Co-authored-by: Amp amp@ampcode.com

worstell and others added 6 commits February 25, 2026 10:55
Homebrew portable-ruby stopped publishing new releases (latest: 3.4.6).
Source newer Ruby versions from spinel-coop/rv-ruby, which publishes
portable, statically-linked binaries using the same build formulas.

Removes the auto-version block that watched the now-stale
Homebrew/homebrew-portable-ruby releases.

Co-authored-by: Amp <amp@ampcode.com>
ruby: add versions 3.2.10, 3.3.9-10, 3.4.7-8, 4.0.x from rv-ruby
rv-ruby statically links OpenSSL and libyaml into its built-in extensions,
but gem native extensions recompile and dynamically link against the system
libs. Ubuntu 24.04 ships OpenSSL 3.0.x which is too old. Set
BUNDLE_BUILD__OPENSSL and LD_LIBRARY_PATH on Linux to use linuxbrew's
OpenSSL and libyaml. macOS is unaffected.

Amp-Thread-ID: https://ampcode.com/threads/T-019c9632-b6b8-724a-af79-d30573ba186a
Co-authored-by: Amp <amp@ampcode.com>
ruby: add Linux OpenSSL/libyaml env for rv-ruby versions
Comment thread ruby.hcl
source = "https://github.com/spinel-coop/rv-ruby/releases/download/${rv_release}/ruby-${version}.x86_64_linux.tar.gz"
env = {
"BUNDLE_BUILD__OPENSSL": "--with-openssl-dir=/home/linuxbrew/.linuxbrew/opt/openssl@3",
"LD_LIBRARY_PATH": "/home/linuxbrew/.linuxbrew/opt/openssl@3/lib:/home/linuxbrew/.linuxbrew/opt/libyaml/lib:${LD_LIBRARY_PATH}",
Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This isn't going to work in the general case...

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

would using $HOMEBREW_PREFIX solve that or are you referring to something else?

Comment thread ruby.hcl
source = "https://github.com/spinel-coop/rv-ruby/releases/download/${rv_release}/ruby-${version}.arm64_linux.tar.gz"
env = {
"BUNDLE_BUILD__OPENSSL": "--with-openssl-dir=/home/linuxbrew/.linuxbrew/opt/openssl@3",
"LD_LIBRARY_PATH": "/home/linuxbrew/.linuxbrew/opt/openssl@3/lib:/home/linuxbrew/.linuxbrew/opt/libyaml/lib:${LD_LIBRARY_PATH}",
Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Same

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

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants