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

installed has error #87

Open
NaturAlex opened this issue Jul 26, 2019 · 3 comments
Open

installed has error #87

NaturAlex opened this issue Jul 26, 2019 · 3 comments

Comments

@NaturAlex
Copy link

i am not good at go.
when i installed,happen:
$ go get github.com/mattn/goreman

github.com/mattn/goreman

/home/gocode/src/github.com/mattn/goreman/proc_posix.go:17: undefined: unix.SysProcAttr
i have config go path,like this:
#GO
export GOROOT=/usr/local/go/go
export GOPATH=/home/gocode

export PATH=$PATH:$NGINX_HOME/sbin:$GOROOT/bin:$GOPATH/bin:$CONSUL_HOME/consul

please~

@mattn
Copy link
Owner

mattn commented Aug 7, 2019

What version of Go do you use? And please show me your go env.

@chaochn47
Copy link

chaochn47 commented Jan 18, 2020

I met the same issue:
Please take a look at it when I first trying to play around setting up a local etcd cluster https://github.com/etcd-io/etcd/tree/master/contrib/raftexample#running-a-local-cluster. Thx!

$ go version
go version go1.12.9 darwin/amd64
$ go env
GOARCH="amd64"
GOBIN=""
GOCACHE="/Users/username/Library/Caches/go-build"
GOEXE=""
GOFLAGS=""
GOHOSTARCH="amd64"
GOHOSTOS="darwin"
GOOS="darwin"
GOPATH="/Users/username/go/"
GOPROXY=""
GORACE=""
GOROOT="/usr/local/go"
GOTMPDIR=""
GOTOOLDIR="/usr/local/go/pkg/tool/darwin_amd64"
GCCGO="gccgo"
CC="clang"
CXX="clang++"
CGO_ENABLED="1"
GOMOD=""
CGO_CFLAGS="-g -O2"
CGO_CPPFLAGS=""
CGO_CXXFLAGS="-g -O2"
CGO_FFLAGS="-g -O2"
CGO_LDFLAGS="-g -O2"
PKG_CONFIG="pkg-config"
GOGCCFLAGS="-fPIC -m64 -pthread -fno-caret-diagnostics -Qunused-arguments -fmessage-length=0 -fdebug-prefix-map=/var/folders/y8/z4s3jgqd21v9g94f9xc_wf1js3wl4f/T/go-build310899481=/tmp/go-build -gno-record-gcc-switches -fno-common"

@chaochn47
Copy link

Fixed that by go get golang.org/x/sys/unix and then navigate to that unix package and git pull from upstream.

It should be work by go get -u golang.org/x/sys/unix but it shows

go get -u golang.org/x/sys/unix
# cd "$GOPATH"/src/golang.org/x/sys; git pull --ff-only
You are not currently on a branch.
Please specify which branch you want to merge with.
See git-pull(1) for details.

So just manully pull from upstream.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants