Skip to content

fix(patches): link WPROGRAM with MAINLIBS in the msys pass-1 GNUmakefile#39

Merged
ronaldtse merged 1 commit into
mainfrom
fix/msys-pass1-wprogram-mainlibs
Jul 25, 2026
Merged

fix(patches): link WPROGRAM with MAINLIBS in the msys pass-1 GNUmakefile#39
ronaldtse merged 1 commit into
mainfrom
fix/msys-pass1-wprogram-mainlibs

Conversation

@ronaldtse

Copy link
Copy Markdown
Contributor

The windows runtime legs (libtfs v0.13.0 x v0.2.4 patches) link rubyw.exe with '-Wl,--start-group $(LIBS) -Wl,--end-group' and fail with undefined tebako_fs_* / tebako_mount_point references from the io-shimmed objects (dir.o & co). In the gem's two-pass flow the toolchain tree carried no io shims at pass-1 time, so LIBS sufficed; the pre-patched pass-1 tree has the shims from the start, and the pass-2 variant of the same rule already links MAINLIBS. Make the pass-1 rule match it (7 files, all lines; the consumer substitutes MAINLIBS into config.status before the toolchain build).

Verified: tools/apply --platform msys --pass 1 for 3.1.6/3.1.7/3.2.4/3.2.7/3.3.3/3.3.7/3.4.2/4.0.6 -- every tree's WPROGRAM rule carries --start-group $(MAINLIBS); tools/lint 3.3.7 + 4.0.6 clean.

Next step after merge: tag v0.2.5 so tebako-runtime-ruby's windows legs consume the fixed scenario.

The windows runtime legs (libtfs v0.13.0 x v0.2.4 patches) link
rubyw.exe with '-Wl,--start-group $(LIBS) -Wl,--end-group' and fail
with undefined tebako_fs_* / tebako_mount_point references from the
io-shimmed objects (dir.o & co). In the gem's two-pass flow the
toolchain tree carried no io shims at pass-1 time, so LIBS sufficed;
the pre-patched pass-1 tree has the shims from the start, and the
pass-2 variant of the same rule already links MAINLIBS. Make the
pass-1 rule match it (7 files, all lines; the consumer substitutes
MAINLIBS into config.status before the toolchain build).

Verified: tools/apply --platform msys --pass 1 for 3.1.6/3.1.7/
3.2.4/3.2.7/3.3.3/3.3.7/3.4.2/4.0.6 -- every tree's WPROGRAM rule
carries --start-group $(MAINLIBS); tools/lint 3.3.7 + 4.0.6 clean.
@ronaldtse
ronaldtse merged commit 7baaf33 into main Jul 25, 2026
41 checks passed
@ronaldtse
ronaldtse deleted the fix/msys-pass1-wprogram-mainlibs branch July 25, 2026 15:59
ronaldtse added a commit to tamatebako/tebako-runtime-ruby that referenced this pull request Jul 25, 2026
v0.2.5 carries the pass-1 WPROGRAM MAINLIBS link fix
(tamatebako/ruby#39) on top of the v0.2.4 F_GETFL guard
(tamatebako/ruby#38): the windows legs' rubyw.exe link now gets the
tebako library set.
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.

1 participant