hajimehoshi / ebiten

Ebitengine - A dead simple 2D game engine for Go
https://ebitengine.org
Apache License 2.0
11.12k stars 664 forks source link

cmd/ebitenmobile: bind failed on Windows with `vim-floaterm` #1666

Open raa0121 opened 3 years ago

raa0121 commented 3 years ago

ebitenmobile bind -target android is failed.

log

C:\home\develop\UnaRPG>ebitenmobile bind -target android -javapkg info.raa0121.una_rpg -o mobile\android\mobile\mobile.aar -x .\mobile
PATH=C:\Users\raa0121\AppData\Local\Temp\ebitenmobile-373339819\bin;D:\android-sdk\cmake\3.18.1\bin;C:\home\go\bin;C:\Users\raa0121\sdk\go1.16.1\bin;C:\home\bin;C:\msys64\mingw64\bin;C:\msys64\usr\bin;C:\Program Files (x86)\Common Files\Oracle\Java\javapath;C:\Python37\Scripts\;C:\Python37\;C:\Program Files (x86)\Intel\iCLS Client\;C:\Program Files\Common Files\VSL Utils\;C:\ProgramData\Oracle\Java\javapath;C:\Program Files\Intel\iCLS Client\;C:\WINDOWS\system32;C:\WINDOWS;C:\WINDOWS\System32\Wbem;C:\WINDOWS\System32\WindowsPowerShell\v1.0\;C:\Program Files (x86)\SoftKinetic\DepthSenseSDK\bin;C:\Program Files\SoftKinetic\DepthSenseSDK\bin;C:\Program Files\Microsoft SQL Server\130\Tools\Binn\;C:\Program Files\dotnet\;C:\Program Files (x86)\GtkSharp\2.12\bin;C:\Program Files\Git\cmd;C:\Program Files (x86)\Intel\Intel(R) Management Engine Components\DAL;C:\Program Files\Intel\Intel(R) Management Engine Components\DAL;C:\Program Files (x86)\Intel\Intel(R) Management Engine Components\IPT;C:\Program Files\Intel\Intel(R) Management Engine Components\IPT;C:\WINDOWS\System32\OpenSSH\;C:\Program Files\NVIDIA Corporation\NVIDIA NvDLISR;C:\WINDOWS\system32;C:\WINDOWS;C:\WINDOWS\System32\Wbem;C:\WINDOWS\System32\WindowsPowerShell\v1.0\;C:\WINDOWS\System32\OpenSSH\;D:\Program\VIPAccessClient\;C:\Program Files (x86)\Windows Kits\8.1\Windows Performance Toolkit\;C:\Program Files (x86)\Windows Kits\10\Windows Performance Toolkit\;C:\PROGRA~1\JPKI;D:\Program\GtkSharp\2.12\bin;C:\Program Files\Git LFS;C:\Program Files (x86)\Common Files\Acronis\VirtualFile\;C:\Program Files (x86)\Common Files\Acronis\VirtualFile64\;C:\Program Files (x86)\Common Files\Acronis\SnapAPI\;C:\Users\raa0121\.wasmer\bin;C:\Users\raa0121\.wasmer\globals\wapm_packages\.bin;C:\Program Files (x86)\NVIDIA Corporation\PhysX\Common;C:\Program Files\Microsoft SQL Server\Client SDK\ODBC\170\Tools\Binn\;C:\Program Files (x86)\dotnet\;;C:\Program Files\Docker\Docker\resources\bin;C:\ProgramData\DockerDesktop\version-bin;D:\Program\Scoop\apps\ruby\current\gems\bin;D:\Program\Scoop\apps\ruby\current\bin;D:\Program\Scoop\shims;D:\Applications\Scoop\shims;C:\Users\raa0121\scoop\shims;C:\Users\raa0121\AppData\Local\Microsoft\WindowsApps;C:\Users\raa0121\AppData\Roaming\npm;C:\Program Files\Docker Toolbox;C:\texlive\2017\bin\win32;D:\Program\Oni;C:\Users\raa0121\AppData\Local\hyper\app-3.0.2\resources\bin;C:\Users\raa0121\.dotnet\tools;C:\Users\raa0121\.wasmer\bin;C:\Users\raa0121\AppData\Local\Microsoft\WindowsApps;;C:\Users\raa0121\AppData\Roaming\Amazon;C:\Users\raa0121\.dotnet\tools;C:\msys64\mingw64\bin;C:\home\.cache\dein\.cache\.vimrc\.dein\bin\
cd C:\Users\raa0121\AppData\Local\Temp\ebitenmobile-373339819
GO111MODULE=on go mod init ebitenmobiletemporary
GO111MODULE=on go get golang.org/x/mobile/cmd/gomobile@bdb1ca9a1e083af5929a8214e8a056d638ebbf2d
GO111MODULE=on go build -o bin\gomobile.exe golang.org/x/mobile/cmd/gomobile
GO111MODULE=on go build -o bin\gobind-original.exe golang.org/x/mobile/cmd/gobind
GO111MODULE=on go build -o bin\gobind.exe -tags ebitenmobilegobind src\gobind.go
gomobile init
GOMOBILE=C:\home\go\pkg\gomobile
WORK=C:\Users\raa0121\AppData\Local\Temp\gomobile-work-324735371
rm -r -f "$WORK"
gomobile: gobind was not found. Please run gomobile init before trying again.

go env

set GO111MODULE=
set GOARCH=amd64
set GOBIN=
set GOCACHE=C:\Users\raa0121\AppData\Local\go-build
set GOENV=C:\Users\raa0121\AppData\Roaming\go\env
set GOEXE=.exe
set GOFLAGS=
set GOHOSTARCH=amd64
set GOHOSTOS=windows
set GOINSECURE=
set GOMODCACHE=C:\home\go\pkg\mod
set GONOPROXY=
set GONOSUMDB=
set GOOS=windows
set GOPATH=C:\home\go
set GOPRIVATE=
set GOPROXY=https://proxy.golang.org,direct
set GOROOT=C:\Users\raa0121\sdk\go1.16.1
set GOSUMDB=sum.golang.org
set GOTMPDIR=
set GOTOOLDIR=C:\Users\raa0121\sdk\go1.16.1\pkg\tool\windows_amd64
set GOVCS=
set GOVERSION=go1.16.1
set GCCGO=gccgo
set AR=ar
set CC=gcc
set CXX=g++
set CGO_ENABLED=1
set GOMOD=C:\home\develop\UnaRPG\go.mod
set CGO_CFLAGS=-g -O2
set CGO_CPPFLAGS=
set CGO_CXXFLAGS=-g -O2
set CGO_FFLAGS=-g -O2
set CGO_LDFLAGS=-g -O2
set PKG_CONFIG=pkg-config
set GOGCCFLAGS=-m64 -mthreads -fmessage-length=0 -fdebug-prefix-map=C:\Users\raa0121\AppData\Local\Temp\go-build1907452998=/tmp/go-build -gno-record-gcc-switches
hajimehoshi commented 3 years ago

Thank you, I'm taking a look

hajimehoshi commented 3 years ago

The reported told that this can be reproduced when vim-floaterm is used. I think ebitenmobile is not to blame, there should be workaround though.

vim-floaterm might interfere a child process when it is executed. Actually the content of PATH environment in the child process (gomobile) was not expected.