Skip to content

x/mobile: os.Executable() panic on Xcode16 #72966

Open
@invented-pro

Description

@invented-pro

Go version

go1.24.1 darwin/arm64

Output of go env in your module/workspace:

AR='ar'
CC='clang'
CGO_CFLAGS='-O2 -g'
CGO_CPPFLAGS=''
CGO_CXXFLAGS='-O2 -g'
CGO_ENABLED='1'
CGO_FFLAGS='-O2 -g'
CGO_LDFLAGS='-O2 -g'
CXX='clang++'
GCCGO='gccgo'
GO111MODULE='on'
GOARCH='arm64'
GOARM64='v8.0'
GOAUTH='netrc'
GOBIN=''
GOCACHE='/Users/sun/Library/Caches/go-build'
GOCACHEPROG=''
GODEBUG=''
GOENV='/Users/sun/Library/Application Support/go/env'
GOEXE=''
GOEXPERIMENT=''
GOFIPS140='off'
GOFLAGS=''
GOGCCFLAGS='-fPIC -arch arm64 -pthread -fno-caret-diagnostics -Qunused-arguments -fmessage-length=0 -ffile-prefix-map=/var/folders/fx/t6n0q569167394bhkc1gp9mh0000gn/T/go-build426215983=/tmp/go-build -gno-record-gcc-switches -fno-common'
GOHOSTARCH='arm64'
GOHOSTOS='darwin'
GOINSECURE=''
GOMOD='/Users/sun/Documents/GitHub/tslib/go.mod'
GOMODCACHE='/Users/sun/go/pkg/mod'
GONOPROXY=''
GONOSUMDB=''
GOOS='darwin'
GOPATH='/Users/sun/go'
GOPRIVATE=''
GOPROXY='https://goproxy.cn,direct'
GOROOT='/Users/sun/go/pkg/mod/golang.org/[email protected]'
GOSUMDB='sum.golang.org'
GOTELEMETRY='off'
GOTELEMETRYDIR='/Users/sun/Library/Application Support/go/telemetry'
GOTMPDIR=''
GOTOOLCHAIN='auto'
GOTOOLDIR='/Users/sun/go/pkg/mod/golang.org/[email protected]/pkg/tool/darwin_arm64'
GOVCS=''
GOVERSION='go1.24.1'
GOWORK=''
PKG_CONFIG='pkg-config'

What did you do?

Use "gomobile bind -target=ios" to build a xcframework library, used in Flutter iOS app.

What did you see happen?

When using Xcode 15.0(15A240d), os.Executable() returns “/var/containers/Bundle/Application/E80602C7-EFFB-4F1B-9FF8-FBA0E7E3DA76/Runner.app/Runner” as normal. All goes fine.

But with Xcode 16.2(16C5032a), os.Executable() panic with err “cannot find executable path”.

What did you expect to see?

os.Executable() should return executable path as before on Xcode 16.

Metadata

Metadata

Assignees

No one assigned

    Labels

    NeedsInvestigationSomeone must examine and confirm this is a valid issue and not a duplicate of an existing one.OS-iOSGOOS=iosWaitingForInfoIssue is not actionable because of missing required information, which needs to be provided.mobileAndroid, iOS, and x/mobile

    Type

    No type

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions