Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Ruby-Packer - Multi Ruby Version / Multi-Arch (Arm64 MacOS / Linux) / Configurable Vendors #177

Closed
wants to merge 87 commits into from

Conversation

YOU54F
Copy link

@YOU54F YOU54F commented Aug 29, 2023

Hey hey,

Took a look at Ruby-Packer after fiddling with traveling-ruby to get it working with the latest version of Ruby, and cross-arch (arm64 for macos and linux inc alpine).

Built on some work by others, which pulled in the Ruby 3.1 source.

Taken a couple of design choices

  • Pull Ruby source on the fly (allows configuring of ruby version)
    • Use pre-patched enclose.io Ruby sources, which are applied onto the ruby source
      • These need to be prepared for each version, the same code applied from 2.7 -> 3.3.0-preview1 for the enclose.io hacks, so they could just be inserted into the code, without storing a full copy of the modified ruby source files.
  • Pull vendored libs on the fly
    • Allows easier testing of updates for vendors
      • Example, building with OpenSSL 1.1.x, 3.0.x and 3.1.x depending on the users requirements

There are other things I need to write up, planning on writing a blog post about the state of Ruby packaging in 2023, which isn't bad at all.

TL;DR of the blog post will be

Basically use Tebako

  • Ocra revisited for Ruby 3.2.2 via a fork titled Ocran
  • Traveling-ruby
    revisted for Ruby 2.6.10 -> 3.3.0-preview1 and arm64 MacOS/Windows in this fork
  • Rb2exe revisted to use the updated traveling-ruby releases in this fork
  • Ruby-packer
    • updated to build against ruby 3.1 in this fork
    • updated to build against multiple rubies, in this fork
  • Newcomer Tebako which builds upon principles in ruby-packer
    • Tebako is an executable packager. It packages a set of files into a DwarFS file system for read-only purposes, some details about the makeup in this blog post
    • evaluated by its author here in an SO post, this is where I randomly stumbled up on it, after working on some of the other ruby packaging projects
    • Just announced a remix of Ocra
  • Crystal
    • Ok maybe this is cheating, but using LLVM and ruby like syntax, it offers an incredibly speedy way to build cross platform, small portable binaries. I've been tickling it to build dependency free MacOS builds.

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