Skip to content

windows: scope LLVM 19 host flags to the binding package - #49

Draft
cpunion wants to merge 4 commits into
xgo-dev:xgofrom
cpunion:codex/windows-host-build-20260815
Draft

windows: scope LLVM 19 host flags to the binding package#49
cpunion wants to merge 4 commits into
xgo-dev:xgofrom
cpunion:codex/windows-host-build-20260815

Conversation

@cpunion

@cpunion cpunion commented Aug 22, 2026

Copy link
Copy Markdown

Supports the LLGo Windows proposal: xgo-dev/llgo#2325.

Use a Windows-only pkg-config directive for LLVM 19 instead of requiring callers to export CGO_CFLAGS/CXXFLAGS/LDFLAGS globally. The public pkg-config module name is the neutral llvm-19; LLGo generates that metadata from llvm-config in its own dependency setup. This keeps LLVM host flags local to github.com/xgo-dev/llvm and prevents them from contaminating unrelated cgo packages or programs launched by compiler tests.

Also makes the archive missing-file assertion portable to the escaped Windows path already emitted by WriteArchive.

The existing upstream test workflow now includes a Windows job. It pins MSYS2 LLVM 19.1.7, generates the neutral metadata directly from llvm-config, and runs both the explicit llvm19 build tag and the default LLVM configuration, so the Windows path is covered by the PR itself rather than only downstream LLGo CI.

Validated locally with Go 1.26.7 and LLVM 19 on Windows 11 ARM64, and with the full test suite on macOS ARM64.

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