feat: add smalruby3 launcher command (rsdl replacement)#404
Merged
Conversation
341c491 to
b9777c6
Compare
Build a native smalruby3 binary that wraps SDL_main + ruby_init, solving the macOS main thread requirement for SDL2. Users can run scripts with `smalruby3 script.rb` instead of `rsdl`. - ext/smalruby3_launcher/: C source and extconf.rb (based on rsdl) - gemspec: add launcher as second extension - .standard.yml: exclude extconf.rb from lint (mkmf globals) Closes #403 Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
b9777c6 to
f82c3b1
Compare
|
🚀 Preview deployed: https://smalruby.jp/smalruby3-editor/feature/smalruby3-launcher-command/ |
github-actions Bot
pushed a commit
that referenced
this pull request
Mar 27, 2026
…uby3-launcher-command feat: add smalruby3 launcher command (rsdl replacement)
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
smalruby3コマンドを gem に内蔵。rsdl の別途インストールが不要に。macOS では SDL2 が Cocoa のメインスレッドで初期化される必要があり、通常の
rubyコマンドでは segfault する。rsdl と同じ仕組み(SDL_main + ruby_init + ruby_run_node)を smalruby3 gem 内にバンドル。使い方
変更点
ext/smalruby3_launcher/: C ソース + extconf.rb(rsdl ベース)smalruby3.gemspec: launcher を追加 extension として登録.standard.yml: extconf.rb を lint 除外(mkmf グローバル変数).gitignore: ビルド成果物を除外Closes #403
🤖 Generated with Claude Code