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 -n does not work on tip #13323

Closed
sridharv opened this issue Nov 19, 2015 · 1 comment
Closed

x/mobile/cmd/gomobile: gomobile bind -n does not work on tip #13323

sridharv opened this issue Nov 19, 2015 · 1 comment

Comments

@sridharv
Copy link

gomobile at commit b39ed682d87b8df3698bcbc8fbaff91efbaa9d17

Running

$ gomobile bind -n golang.org/x/mobile/asset 

results in the following error

GOOS=android GOARCH=arm GOARM=7 CC=$GOMOBILE/android-ndk-r10e/arm/bin/arm-linux-androideabi-gcc CXX=$GOMOBILE/android-ndk-r10e/arm/bin/arm-linux-androideabi-g++ CGO_ENABLED=1 go install -p=4 -pkgdir=$GOMOBILE/pkg_android_arm -tags="" -gcflags=-shared -ldflags=-shared golang.org/x/mobile/asset
rm -r -f "$WORK/fakegopath"
mkdir -p $WORK/fakegopath/pkg
mkdir -p $WORK/fakegopath/pkg/android_arm/golang.org/x/mobile
gomobile: can't find import: golang.org/x/mobile/asset

instead of listing all operations without running them.

The issue was introduced in commit d4beed2e0a6d9bba239b768f8962e9ee61efeeaa. Due to the -n flag, the go install command is not being run, resulting in the export data loading code not being able to locate the installed packages. This also breaks TestAndroidBind in bind_test.go

@crawshaw crawshaw self-assigned this Nov 19, 2015
@gopherbot
Copy link

CL https://golang.org/cl/17090 mentions this issue.

@golang golang locked and limited conversation to collaborators Nov 27, 2016
imWildCat pushed a commit to imWildCat/go-mobile that referenced this issue Apr 10, 2021
Fixes golang/go#13323.

Change-Id: Ica213b7d06581ac7a0492184a903752cfa15d889
Reviewed-on: https://go-review.googlesource.com/17090
Reviewed-by: Hyang-Ah Hana Kim <hyangah@gmail.com>
imWildCat pushed a commit to imWildCat/go-mobile that referenced this issue Apr 11, 2021
Fixes golang/go#13323.

Change-Id: Ica213b7d06581ac7a0492184a903752cfa15d889
Reviewed-on: https://go-review.googlesource.com/17090
Reviewed-by: Hyang-Ah Hana Kim <hyangah@gmail.com>
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

3 participants