问题描述
在执行 .\javascript\build.bat
后的响应如下
(base) PS D:\Develop\lute> .\javascript\build.bat
D:\Develop\lute>SET GOOS=linux
D:\Develop\lute>go list -tags javascript -f {{.Deps}}
[bufio bytes errors github.com/88250/lute/ast github.com/88250/lute/html github.com/88250/lute/html/atom github.com/88250/lute/lex github.com/88250/lute/parse github.com/88250/lute/render github.com/88250/lu
te/util github.com/gopherjs/gopherjs/js internal/bytealg internal/cpu internal/race io math math/bits math/rand runtime runtime/internal/atomic runtime/internal/math runtime/internal/sys strconv strings sync
sync/atomic syscall time unicode unicode/utf8 unsafe]
D:\Develop\lute>gopherjs build --tags javascript -o lute.min.js -m
?[31mcannot find package "github.com/88250/lute/ast" in any of:
D:\Develop\go-sdk\go1.12.17\src\github.com\88250\lute\ast (from $GOROOT)
D:\Develop\go-sdk\gopath\src\github.com\88250\lute\ast (from $GOPATH)
?[39m
执行环境
set GOARCH=amd64
set GOBIN=
set GOCACHE=C:\Users\qq785\AppData\Local\go-build
set GOEXE=
set GOFLAGS= -mod=
set GOHOSTARCH=amd64
set GOHOSTOS=windows
set GOOS=linux
set GOPATH=D:\Develop\go-sdk\gopath
set GOPROXY=https://goproxy.cn
set GORACE=
set GOROOT=D:\Develop\go-sdk\go1.12.17
set GOTMPDIR=
set GOTOOLDIR=D:\Develop\go-sdk\go1.12.17\pkg\tool\windows_amd64
set GCCGO=gccgo
set CC=gcc
set CXX=g++
set CGO_ENABLED=0
set GOMOD=D:\Develop\lute\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=-fPIC -m64 -fno-caret-diagnostics -Qunused-arguments -fmessage-length=0 -fdebug-prefix-map=C:\Users\qq785\AppData\Local\Temp\go-build877371510=/tmp/go-build -gno-record-gcc-switches
遇到的困境
我了解到,现有的 go module 模式,默认是会把包安装到 GOPATH/pkg/mod
下的,并不会和 $GOPATH/src
有关系,所以我就懵逼了。。。请知道的大神不吝赐教
欢迎来到这里!
我们正在构建一个小众社区,大家在这里相互信任,以平等 • 自由 • 奔放的价值观进行分享交流。最终,希望大家能够找到与自己志同道合的伙伴,共同成长。
注册 关于