fix(pty): link Ghostty statically and add Windows CI - #8
Merged
Conversation
jlongster
marked this pull request as ready for review
September 2, 2026 16:54
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
Add Windows x64/ARM64 build-and-test CI and fix the native dependency linkage exposed by running it. No terminal transport implementation, packaging changes, or OpenCode integration.
Fix the Unicode crash
The published
libghostty-vt-sys0.2.1 validatesghostty-vt-static.libbut linksghostty-vt.lib, which is the Windows DLL import library. Windows debugger output confirmed the Unicode test was loadingghostty-vt.dlland crashing insimdutf::convert_utf8_to_utf32_with_errorswhile processing non-ASCII input.Pin the matching Rust bindings to upstream commit
bac73b914d936e945de4a6b93bed75ae1ce8895c, which fixes MSVC static linking. That revision requires Zig 0.16.0, so both CI workflows use that version. No vendored dependency, local linker override, or test skip is retained.Windows CI
masterpushes, and manual dispatch after the workflow reachesmaster; avoid duplicate push/PR runs for feature branchesARM64 tooling is explicitly documented: native ARM64 Zig 0.16 crashes during the dependency build, so that job uses x64-hosted Rust/Zig compilers targeting ARM64 on the ARM64 runner. It also applies a guarded one-line
@alignCastfix to Zig 0.16's Windows stack-trace helper, which otherwise fails to compile ARM64 function pointers. The resulting test executables are ARM64 and run natively, not through x64 emulation.Verification
Green Windows run: https://github.com/anomalyco/opencode-pty/actions/runs/33663737280
cargo fmt --check,cargo clippy --all-targets --all-features -- -D warnings, all 32 tests in debug and release profiles passactionlint .github/workflows/windows.ymlpassesThe original Unicode test remains unchanged. The existing service, ownership, playground, and rows integration suites are still Unix-gated; this PR does not claim Windows named-pipe transport or ConPTY lifecycle support is implemented.