Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

x/mobile/cmd/gomobile: gomobile bind fails with Xcode 15 #63141

Closed
hajimehoshi opened this issue Sep 21, 2023 · 12 comments
Closed

x/mobile/cmd/gomobile: gomobile bind fails with Xcode 15 #63141

hajimehoshi opened this issue Sep 21, 2023 · 12 comments
Labels
mobile Android, iOS, and x/mobile NeedsFix The path to resolution is known, but the work has not been done.
Milestone

Comments

@hajimehoshi
Copy link
Member

What version of Go are you using (go version)?

$ go version
go version go1.21.1 darwin/amd64

Does this issue reproduce with the latest release?

Yes

What operating system and processor architecture are you using (go env)?

go env Output
$ go env
GO111MODULE=''
GOARCH='amd64'
GOBIN=''
GOCACHE='/Users/hajimehoshi/Library/Caches/go-build'
GOENV='/Users/hajimehoshi/Library/Application Support/go/env'
GOEXE=''
GOEXPERIMENT=''
GOFLAGS=''
GOHOSTARCH='amd64'
GOHOSTOS='darwin'
GOINSECURE=''
GOMODCACHE='/Users/hajimehoshi/go/pkg/mod'
GONOPROXY=''
GONOSUMDB=''
GOOS='darwin'
GOPATH='/Users/hajimehoshi/go'
GOPRIVATE=''
GOPROXY='https://proxy.golang.org,direct'
GOROOT='/usr/local/go'
GOSUMDB='sum.golang.org'
GOTMPDIR=''
GOTOOLCHAIN='auto'
GOTOOLDIR='/usr/local/go/pkg/tool/darwin_amd64'
GOVCS=''
GOVERSION='go1.21.1'
GCCGO='gccgo'
GOAMD64='v1'
AR='ar'
CC='clang'
CXX='clang++'
CGO_ENABLED='1'
GOMOD='/Users/hajimehoshi/go-x-mobile/go.mod'
GOWORK=''
CGO_CFLAGS='-O2 -g'
CGO_CPPFLAGS=''
CGO_CXXFLAGS='-O2 -g'
CGO_FFLAGS='-O2 -g'
CGO_LDFLAGS='-O2 -g'
PKG_CONFIG='pkg-config'
GOGCCFLAGS='-fPIC -arch x86_64 -m64 -pthread -fno-caret-diagnostics -Qunused-arguments -fmessage-length=0 -ffile-prefix-map=/var/folders/60/khbk2xqn1c5bml1byjn89dwc0000gn/T/go-build2181238540=/tmp/go-build -gno-record-gcc-switches -fno-common'

What did you do?

Install Xcode 15.0.

In gomobile directory, run

gomobile bind -target=ios ./example/bind/hello/

What did you expect to see?

This command succeeds

What did you see instead?

This command fails:

gomobile: xcodebuild -create-xcframework -framework /var/folders/60/khbk2xqn1c5bml1byjn89dwc0000gn/T/gomobile-work-3454804453/ios/iphoneos/Hello.framework -framework /var/folders/60/khbk2xqn1c5bml1byjn89dwc0000gn/T/gomobile-work-3454804453/iossimulator/iphonesimulator/Hello.framework -framework /var/folders/60/khbk2xqn1c5bml1byjn89dwc0000gn/T/gomobile-work-3454804453/iossimulator/iphonesimulator/Hello.framework -output Hello.xcframework failed: exit status 70
error: cannot compute path of binary 'Path(str: "/private/var/folders/60/khbk2xqn1c5bml1byjn89dwc0000gn/T/gomobile-work-3454804453/ios/iphoneos/Hello.framework/Versions/A/Hello")' relative to that of '/var/folders/60/khbk2xqn1c5bml1byjn89dwc0000gn/T/gomobile-work-3454804453/ios/iphoneos/Hello.framework'

/CC @hyangah @dmitshur

@gopherbot gopherbot added the mobile Android, iOS, and x/mobile label Sep 21, 2023
@gopherbot gopherbot added this to the Unreleased milestone Sep 21, 2023
@hajimehoshi
Copy link
Member Author

I'm sending a CL soon.

@gopherbot
Copy link

Change https://go.dev/cl/530135 mentions this issue: cmd/gomobile: resolve symblic links as a workaround for an Xcode bug

@dmitshur dmitshur added the NeedsFix The path to resolution is known, but the work has not been done. label Sep 21, 2023
@brave723
Copy link

so,how to slove it?

@brave723
Copy link

I'm sending a CL soon.

please send your cl

@hajimehoshi
Copy link
Member Author

please send your cl

#63141 (comment)

@brave723
Copy link

please send your cl

#63141 (comment)

thanks , I have slove, rebuild gomobile

@cherrymui
Copy link
Member

@hajimehoshi on the CL you mentioned that this is likely a bug in xcodebuild in Xcode 15. Have you reported it to Apple? Thanks.

@hajimehoshi
Copy link
Member Author

No, I have not.

@hajimehoshi
Copy link
Member Author

hajimehoshi commented Sep 22, 2023

I reported the issue to the forum. This is under review now.

EDIT: https://developer.apple.com/forums/thread/738070

@cherrymui
Copy link
Member

Thanks.

@losh11
Copy link

losh11 commented Oct 5, 2023

Is there a temp fix for this bug?

@cherrymui
Copy link
Member

This is already fixed in the latest version of gomobile. Please update gomobile. Thanks.

siddarthkay added a commit to status-im/status-go that referenced this issue Apr 9, 2024
This issue exists in `gomobile` here -> golang/go#63141
This commit makes sure `make statusgo-ios` works with Xcode 15 by applying this patch on top of our existing `gomobile` overlay.

Closes #5034
siddarthkay added a commit to status-im/status-go that referenced this issue Apr 10, 2024
This issue exists in `gomobile` here -> golang/go#63141
This commit makes sure `make statusgo-ios` works with Xcode 15 by applying this patch on top of our existing `gomobile` overlay.

Closes #5034
siddarthkay added a commit to status-im/status-go that referenced this issue Apr 10, 2024
This issue exists in `gomobile` here -> golang/go#63141
This commit makes sure `make statusgo-ios` works with Xcode 15 by applying this patch on top of our existing `gomobile` overlay.

Closes #5034
siddarthkay added a commit to status-im/status-go that referenced this issue Apr 10, 2024
This issue exists in `gomobile` here -> golang/go#63141
This commit makes sure `make statusgo-ios` works with Xcode 15 by applying this patch on top of our existing `gomobile` overlay.

Closes #5034
siddarthkay added a commit to status-im/status-go that referenced this issue Apr 10, 2024
This issue exists in `gomobile` here -> golang/go#63141
This commit makes sure `make statusgo-ios` works with Xcode 15 by applying this patch on top of our existing `gomobile` overlay.

Closes #5034
siddarthkay added a commit to status-im/status-go that referenced this issue Apr 10, 2024
This issue exists in `gomobile` here -> golang/go#63141
This commit makes sure `make statusgo-ios` works with Xcode 15 by applying this patch on top of our existing `gomobile` overlay.

Closes #5034
siddarthkay added a commit to status-im/status-go that referenced this issue Apr 10, 2024
This issue exists in `gomobile` here -> golang/go#63141
This commit makes sure `make statusgo-ios` works with Xcode 15 by applying this patch on top of our existing `gomobile` overlay.

Closes #5034
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
mobile Android, iOS, and x/mobile NeedsFix The path to resolution is known, but the work has not been done.
Projects
None yet
Development

No branches or pull requests

6 participants