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

gccgo: implement plugin package #36403

Open
zhsj opened this issue Jan 6, 2020 · 2 comments
Open

gccgo: implement plugin package #36403

zhsj opened this issue Jan 6, 2020 · 2 comments

Comments

@zhsj
Copy link

@zhsj zhsj commented Jan 6, 2020

What version of Go are you using (go version)?

$ go version
go version go1.12.2 gccgo (Debian 9.2.1-21) 9.2.1 20191130 linux/amd64

Does this issue reproduce with the latest release?

What operating system and processor architecture are you using (go env)?

go env Output
$ go env
GOARCH="amd64"
GOBIN=""
GOCACHE="/home/zhsj/.cache/go-build"
GOEXE=""
GOFLAGS=""
GOHOSTARCH="amd64"
GOHOSTOS="linux"
GOOS="linux"
GOPATH="/home/zhsj/go"
GOPROXY="https://proxy.golang.org"
GORACE=""
GOROOT="/usr"
GOTMPDIR=""
GOTOOLDIR="/usr/lib/gcc/x86_64-linux-gnu/9"
GCCGO="/usr/bin/x86_64-linux-gnu-gccgo-9"
CC="x86_64-linux-gnu-gcc-9"
CXX="x86_64-linux-gnu-g++-9"
CGO_ENABLED="1"
GOMOD="/home/zhsj/go/src/github.com/containerd/containerd/go.mod"
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 -fmessage-length=0 -fdebug-prefix-map=/tmp/go-build814416476=/tmp/go-build -gno-record-gcc-switches -funwind-tables"

What did you do?

build containerd with gccgo

go-9 build -tags "no_btrfs no_cri" -v ./cmd/containerd
plugin/plugin_go18.go:24:2: cannot find package "plugin" in any of:
        /home/zhsj/go/src/github.com/containerd/containerd/vendor/plugin (vendor tree)
        /usr/src/plugin (from $GOROOT)
        /home/zhsj/go/src/plugin (from $GOPATH)

I'm not sure if it's distribution issue or upstream issue. I didn't see plugin in /usr/lib/x86_64-linux-gnu/go/9/x86_64-linux-gnu/. But I see plugin in https://github.com/golang/gofrontend/tree/master/libgo/go/plugin

Is https://github.com/golang/gofrontend/blob/master/libgo/libgo-packages.txt responsible for it? I didn't see plugin in it too.

What did you expect to see?

What did you see instead?

@gopherbot gopherbot added this to the Gccgo milestone Jan 6, 2020
@ianlancetaylor
Copy link
Contributor

@ianlancetaylor ianlancetaylor commented Jan 6, 2020

Yes: gccgo does not currently implement the plugin package. Sorry.

zhsj added a commit to zhsj/containerd that referenced this issue Jan 7, 2020
+ archive: don't convert syscall.Timespec to unix.Timespec
  archive/tar_unix.go:179:76: error: invalid type conversion (cannot use type syscall.Timespec as type unix.Timespec)
    179 |  timespec := []unix.Timespec{unix.Timespec(fs.StatAtime(st)), unix.Timespec(fs.StatMtime(st))}
+ gccgo has no plugin support
  golang/go#36403
+ update github.com/containerd/continuity
  to include same fix for Timespec

Signed-off-by: Shengjing Zhu <zhsj@debian.org>
zhsj added a commit to zhsj/containerd that referenced this issue Jan 7, 2020
+ archive: don't convert syscall.Timespec to unix.Timespec
  archive/tar_unix.go:179:76: error: invalid type conversion (cannot use type syscall.Timespec as type unix.Timespec)
    179 |  timespec := []unix.Timespec{unix.Timespec(fs.StatAtime(st)), unix.Timespec(fs.StatMtime(st))}
+ gccgo has no plugin support
  golang/go#36403
+ update github.com/containerd/continuity
  to include same fix for Timespec

Signed-off-by: Shengjing Zhu <zhsj@debian.org>
@ALTree ALTree added NeedsFix and removed NeedsInvestigation labels Jan 8, 2020
@ALTree ALTree changed the title gccgo: no plugin package gccgo: implement plugin package Jan 8, 2020
tussennet pushed a commit to tussennet/containerd that referenced this issue Sep 11, 2020
+ archive: don't convert syscall.Timespec to unix.Timespec
  archive/tar_unix.go:179:76: error: invalid type conversion (cannot use type syscall.Timespec as type unix.Timespec)
    179 |  timespec := []unix.Timespec{unix.Timespec(fs.StatAtime(st)), unix.Timespec(fs.StatMtime(st))}
+ gccgo has no plugin support
  golang/go#36403
+ update github.com/containerd/continuity
  to include same fix for Timespec

Signed-off-by: Shengjing Zhu <zhsj@debian.org>
@advancedwebdeveloper
Copy link

@advancedwebdeveloper advancedwebdeveloper commented Sep 18, 2020

Yes: gccgo does not currently implement the plugin package. Sorry.

@thanm , @ianlancetaylor , @cherrymui :

~/faasd$ make all
CGO_ENABLED=0 GOOS=linux go build -o bin/faasd
../go/src/github.com/openfaas/faasd/vendor/github.com/containerd/containerd/plugin/plugin_go18.go:24:2: cannot find package "plugin" in any of:
/home/oceanfish81/go/src/github.com/openfaas/faasd/vendor/plugin (vendor tree)
/usr/local/src/plugin (from $GOROOT)
/home/oceanfish81/go/src/plugin (from $GOPATH)
make: *** [Makefile:12: local] Error 1

I was trying to build faasd :

$ go env && go version
GO111MODULE=""
GOARCH="amd64"
GOBIN=""
GOCACHE="/home/oceanfish81/.cache/go-build"
GOENV="/home/oceanfish81/.config/go/env"
GOEXE=""
GOFLAGS=""
GOHOSTARCH="amd64"
GOHOSTOS="linux"
GOINSECURE=""
GOMODCACHE="/home/oceanfish81/go/pkg/mod"
GONOPROXY=""
GONOSUMDB=""
GOOS="linux"
GOPATH="/home/oceanfish81/go"
GOPRIVATE=""
GOPROXY="https://proxy.golang.org,direct"
GOROOT="/usr/local"
GOSUMDB="sum.golang.org"
GOTMPDIR=""
GOTOOLDIR="/usr/local/tools"
GCCGO="/usr/local/bin/llvm-goc"
AR="ar"
CC="/usr/bin/clang"
CXX="/usr/bin/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=/tmp/go-build934338008=/tmp/go-build -gno-record-gcc-switches -funwind-tables"
go version go1.15rc2 gollvm LLVM 12.0.0git linux/amd64

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

Successfully merging a pull request may close this issue.

None yet
6 participants
You can’t perform that action at this time.