-
Notifications
You must be signed in to change notification settings - Fork 8
Build fails with Go 1.26 due to gVisor sync runtime constants redeclaration #22
Copy link
Copy link
Closed
Description
Summary
gotun fails to build with Go 1.26.0 due to redeclared constants in gvisor.dev/gvisor/pkg/sync.
Environment
- gotun:
v0.8.0 - Go:
go1.26.0 - OS: macOS arm64 and Linux arm64 (Homebrew CI)
Reproduction
git clone --depth 1 --branch v0.8.0 https://github.com/Sesame2/gotun.git
cd gotun
go version
# go version go1.26.0 ...
go build -trimpath -ldflags='-s -w -X main.Version=0.8.0' ./cmd/gotunError
# gvisor.dev/gvisor/pkg/sync
.../gvisor.dev/gvisor@v0.0.0-20251220000015-517913d17844/pkg/sync/runtime_constants_go126.go:22:2: WaitReasonSelect redeclared in this block
.../gvisor.dev/gvisor@v0.0.0-20251220000015-517913d17844/pkg/sync/runtime_constants_go125.go:22:2: other declaration of WaitReasonSelect
.../runtime_constants_go126.go:23:2: WaitReasonChanReceive redeclared in this block
.../runtime_constants_go125.go:23:2: other declaration of WaitReasonChanReceive
.../runtime_constants_go126.go:24:2: WaitReasonSemacquire redeclared in this block
.../runtime_constants_go125.go:24:2: other declaration of WaitReasonSemacquire
Homebrew references
- PR context: go 1.26.0, go@1.25 1.25.7 (new formula) Homebrew/homebrew-core#258912
- Failing CI job/log section: https://github.com/Homebrew/homebrew-core/actions/runs/21880985907/job/63170336098?pr=258912#step:3:11755
It looks like this may require updating/pinning the gVisor dependency to a revision compatible with Go 1.26 build tags.
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels