Skip to contentSkip to conversation

cri-o: workaround failure since go upgraded to 1.13

PATCH In review hongxu 2 participants 2 messages Dec 1, 2019 – Dec 2, 2019

lore
Share & tools
lore

hongxu

author
#0 lore raw

PATCH v2 1/1 cri-o: workaround failure since go upgraded to 1.13

Since go was upgraded to 1.13, there is a failure:
...
| src/vendor/golang.org/x/net/http2/frame.go:17:2: use of vendored package not allowed
| ../../../recipe-sysroot/usr/lib64/go/src/net/http/h2_bundle.go:49:2: use of vendored package not allowed
...

Refer upstream suggestion [1]:
`or copying your vendor contents into GOPATH/src rather than mapping them in to GOPATH/src/vendor.'

[1] https://github.com/golang/go/issues/34068

---
 recipes-containers/cri-o/cri-o_git.bb | 3 +++
 1 file changed, 3 insertions(+)
recipes-containers/cri-o/cri-o_git.bb +3 -0
index 8d754ec..4fee385 100644
@@ -109,6 +109,9 @@ do_compile() {
 	# fixes the bin/crio build of oe_runmake binaries below
 	ln -sf ../../../../cmd/crio ${S}/src/import/src/github.com/cri-o/cri-o/cmd/
 
+	# workaround `use of vendored package not allowed' failure
+	mv ${S}/src/import/vendor/golang.org  ${S}/src/import/
+
 	cd ${S}/src/import
 
 	if [ "${CRIO_BUILD_CROSS}" = "1" ]; then
Signature · 1 line
2.21.0
#1 lore raw

In message: [meta-virtualization][PATCH V2] cri-o: workaround failure since go upgraded to 1.13

Quoted 11 lines · on 01/12/2019 Hongxu Jia wrote:

Since go was upgraded to 1.13, there is a failure:
...
| src/vendor/golang.org/x/net/http2/frame.go:17:2: use of vendored package not allowed
| ../../../recipe-sysroot/usr/lib64/go/src/net/http/h2_bundle.go:49:2: use of vendored package not allowed
...

Refer upstream suggestion [1]:
`or copying your vendor contents into GOPATH/src rather than mapping them in to GOPATH/src/vendor.'

[1] https://github.com/golang/go/issues/34068

v2 is merged.

Bruce

Quoted 23 lines
---
 recipes-containers/cri-o/cri-o_git.bb | 3 +++
 1 file changed, 3 insertions(+)
recipes-containers/cri-o/cri-o_git.bb +3 -0
index 8d754ec..4fee385 100644
@@ -109,6 +109,9 @@ do_compile() {
 	# fixes the bin/crio build of oe_runmake binaries below
 	ln -sf ../../../../cmd/crio ${S}/src/import/src/github.com/cri-o/cri-o/cmd/
 
+	# workaround `use of vendored package not allowed' failure
+	mv ${S}/src/import/vendor/golang.org  ${S}/src/import/
+
 	cd ${S}/src/import
 
 	if [ "${CRIO_BUILD_CROSS}" = "1" ]; then
Signature · 1 line
2.21.0