Repository navigation
Build the Go bindings with the go.mod toolchain - #292
Open
nakulmanimala wants to merge 1 commit into
Open
nakulmanimala wants to merge 1 commit into
nakulmanimala wants to merge 1 commit into
Conversation
gomobile bind compiles in a temporary module that keeps the netbird submodule's go directive (1.26.0) but drops its toolchain directive (go1.26.7), and actions/setup-go also installs the go-directive release. Releases since v0.6.0 were therefore built with Go 1.26.0, whose 32-bit runtime probes futex_time64. The Android 8-10 seccomp filter kills the app with SIGSYS instead of returning ENOSYS, so armeabi-v7a devices on those releases crash at launch (golang/go#77621, fixed in Go 1.26.3). Export GOTOOLCHAIN from the submodule's toolchain directive so every go invocation, including the one inside gomobile bind, uses the pinned release, in CI and in local builds alike. Fixes netbirdio#272
Contributor
This branch has not been deployed
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.
Fixes #272
Related: netbirdio/netbird#8009
Releases since v0.6.0 crash at launch on 32-bit Android 8–10 (SIGSYS, seccomp blocks
futex_time64). The Go bindings are built with Go 1.26.0 instead of the go.mod toolchain go1.26.7:actions/setup-goreads only thegodirective, andgomobile bindbuilds in a temporary module that drops thetoolchaindirective. Go 1.26.0–1.26.2 have the bug (golang/go#77621).This exports
GOTOOLCHAINfrom the submodule'stoolchainline inbuild-android-lib.sh, so CI and local builds both use the pinned release.Tested:
libgojni.soin the v0.6.2 release APK reportsgo1.26.0. With this change it reportsgo1.26.7, built with go1.26.0 (as CI installs it) and with go1.25.6 on PATH.Summary by CodeRabbit