Fix mobile build on windows

gobind executable name is not exactly `gobind` on windows it's `gobind.exe`

Signed-off-by: Devman <85770917+amir-devman@users.noreply.github.com>
This commit is contained in:
Devman 2024-02-01 05:18:42 +03:30 committed by GitHub
parent 38f76ddd2e
commit b458710595
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -85,8 +85,15 @@ var GoBinPath string
func FindMobile() {
goBin := filepath.Join(build.Default.GOPATH, "bin")
if runtime.GOOS == "windows" {
if !rw.FileExists(goBin + "/" + "gobind.exe") {
log.Fatal("missing gomobile.exe installation")
}
} else {
if !rw.FileExists(goBin + "/" + "gobind") {
log.Fatal("missing gomobile installation")
}
}
GoBinPath = goBin
}