You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Does this issue reproduce with the latest release?
What operating system and processor architecture are you using (go env)?
go env Output
$ go env
D:\checktool>go env
set GO111MODULE=on
set GOARCH=386
set GOBIN=
set GOCACHE=C:\Users\john\AppData\Local\go-build
set GOENV=C:\Users\john\AppData\Roaming\go\env
set GOEXE=.exe
set GOFLAGS=
set GOHOSTARCH=amd64
set GOHOSTOS=windows
set GOINSECURE=
set GONOPROXY=
set GONOSUMDB=
set GOOS=windows
set GOPATH=C:\Users\john\go
set GOPRIVATE=
set GOPROXY=https://goproxy.cn,direct
set GOROOT=c:\go
set GOSUMDB=sum.golang.org
set GOTMPDIR=
set GOTOOLDIR=c:\go\pkg\tool\windows_amd64
set GCCGO=gccgo
set GO386=sse2
set AR=ar
set CC=gcc
set CXX=g++
set CGO_ENABLED=0
set GOMOD=D:\checktool\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=-m32 -fmessage-length=0 -fdebug-prefix-map=C:\Users\john\AppData\
Local\Temp\go-build468324490=/tmp/go-build -gno-record-gcc-switches
Try setting CGO_ENABLED=1. It seems you are cross-compiling from amd64 to 386 (GOHOSTARCH=amd64, GOARCH=386). Cgo is by default disabled with cross-compilation. You need to enable it explicitly.
Try setting CGO_ENABLED=1. It seems you are cross-compiling from amd64 to 386 (GOHOSTARCH=amd64, GOARCH=386). Cgo is by default disabled with cross-compilation. You need to enable it explicitly.
My Question is ok , thank you. --by china developer
@Co0nan This issue is closed. I suggest that you ask your question on a forum. See https://golang.org/wiki/Questions. You will need to provide additional information, like Go version number, operating system, and where your Go installation came from.
What version of Go are you using (
go version
)?Does this issue reproduce with the latest release?
What operating system and processor architecture are you using (
go env
)?go env
OutputWhat did you do?
What did you expect to see?
I want to build go to 32bit dll, but is error.
set GOARCH=amd64 is ok.
What did you see instead?
The text was updated successfully, but these errors were encountered: