cni: inhibit go.mod build for main cni

The cni plugins already have mod=vendor, but we also need to ensure
that the main CNI build is not using go module based builds.

To avoid inconsistent vendoring messages, we switch all plugins to
no module builds as well.

Signed-off-by: Bruce Ashfield <bruce.ashfield@gmail.com>
This commit is contained in:
Bruce Ashfield 2021-06-15 08:51:23 -04:00
parent f5e26f3704
commit cd431b8f44

View File

@ -33,6 +33,8 @@ do_compile() {
mkdir -p ${S}/src/github.com/containernetworking
ln -sfr ${S}/src/import ${S}/src/github.com/containernetworking/cni
export GO111MODULE=off
cd ${B}/src/github.com/containernetworking/cni/libcni
${GO} build
@ -45,7 +47,7 @@ do_compile() {
for p in $PLUGINS; do
plugin="$(basename "$p")"
echo "building: $p"
${GO} build -mod=vendor -o ${B}/plugins/bin/$plugin github.com/containernetworking/plugins/$p
${GO} build -o ${B}/plugins/bin/$plugin github.com/containernetworking/plugins/$p
done
}