Diego Romar 98ec64efd2 fix: resolve bind packages using build info instead of packages.Load
This fixes the 'unable to import bind' error when
gomobile-tvos-fork is installed via 'go install' and
used to build packages outside the fork's module context.

The fix uses debug.ReadBuildInfo() to determine where the fork is
installed (either in GOPATH/src or module cache) and constructs
paths to bind packages directly, avoiding the dependency on
packages.Load which requires packages to be in the current
module's dependency graph.
2026-01-29 11:06:16 -03:00
2025-02-18 09:38:27 -08:00
2015-03-18 17:03:44 +00:00
2024-07-16 16:10:57 +00:00

gomobile with tvOS Support

This is a fork of the official golang.org/x/mobile repository that adds support for Apple tvOS targets.

What's Different

This fork extends gomobile to support building Go libraries for tvOS and tvOS Simulator, in addition to the standard iOS, iOS Simulator, macOS, Mac Catalyst, and Android targets.

Added Targets

  • tvos - Apple tvOS (arm64)
  • tvossimulator - Apple tvOS Simulator (arm64, amd64)

New Build Flag

  • -tvosversion - Minimum tvOS version (default: 13.0)

Usage

Building for tvOS

gomobile-netbird bind -target=tvos ./package

Building for tvOS Simulator

gomobile-netbird bind -target=tvossimulator ./package

Building an XCFramework with tvOS Support

gomobile-netbird bind -target=ios,iossimulator,tvos,tvossimulator -o MyFramework.xcframework ./package

Installation

go install github.com/netbirdio/gomobile-tvos-fork/cmd/gomobile-netbird@latest
go install github.com/netbirdio/gomobile-tvos-fork/cmd/gobind-netbird@latest

Original Project

This fork is based on the Go Mobile project from golang.org/x/mobile. The original project provides:

For general gomobile documentation and usage, see golang.org/wiki/Mobile.

License

This project retains the original BSD-style license from the Go project. See the LICENSE file for details.

S
Description
No description provided
Readme BSD-3-Clause
7.1 MiB
Languages
Go 87%
Objective-C 4.6%
Java 4.6%
C 3.4%
HTML 0.3%
Other 0.1%